testutil

package module
v0.0.0-...-f13642e Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2026 License: AGPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetFreeListener

func GetFreeListener(t *testing.T) *net.TCPListener

func GetFreePort

func GetFreePort(t *testing.T) int

func GetFreePortTest

func GetFreePortTest(t *testing.T) string

func RunPostgres

func RunPostgres(ctx context.Context) (*postgres.PostgresContainer, error)

RunPostgres starts a PostgreSQL container with the settings shared by the Crosslink integration tests.

func WaitForPort

func WaitForPort(t *testing.T, address string, timeout time.Duration)

WaitForPort tries to connect to the specified address until timeout. If the port is not open before the timeout, the test fails.

Types

type MetaproxyContainer

type MetaproxyContainer struct {
	// contains filtered or unexported fields
}

func MetaproxyContainerStart

func MetaproxyContainerStart(ctx context.Context) (*MetaproxyContainer, error)

func (*MetaproxyContainer) ContainerHost

func (c *MetaproxyContainer) ContainerHost() string

func (*MetaproxyContainer) MappedPort

func (c *MetaproxyContainer) MappedPort() string

func (*MetaproxyContainer) Terminate

func (c *MetaproxyContainer) Terminate(ctx context.Context) error

Jump to

Keyboard shortcuts

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