utils

package
v0.4.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 12, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DockerHost added in v0.4.4

func DockerHost() string

DockerHost returns the IP/hostname to use for Kafka's advertised listeners. It mirrors testcontainers' own host resolution so the advertised address matches what container.Host() will return after startup.

func EnvToLabels added in v0.4.3

func EnvToLabels() map[string]string

EnvToLabels converts environment variables with the "TEST_LABEL_" prefix into a label map. The prefix is stripped and underscores are replaced with dots to form the label key; the env value becomes the label value.

func ErrCheck

func ErrCheck[T any](v T, err error) func(t *testing.T) T

func Iter2

func Iter2[K, V any](values ...IterKV[K, V]) iter.Seq2[K, V]

func Iter2Check

func Iter2Check[K, V any](t *testing.T, its iter.Seq2[K, V], values []IterKV[K, V])

Types

type IterKV

type IterKV[K, V any] struct {
	K K
	V V
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL