testutil

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func StartPostgres

func StartPostgres(t *testing.T) string

StartPostgres starts a PostgreSQL container (postgres:18-alpine) and returns a connection string with sslmode=disable. The container is terminated via t.Cleanup. Use in integration tests that need a real database. Do not log the returned connection string without masking it (e.g. postgres.MaskURL).

Types

This section is empty.

Jump to

Keyboard shortcuts

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