testutils

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2025 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CleanupSharedMySQL added in v0.3.0

func CleanupSharedMySQL()

CleanupSharedMySQL terminates the shared MySQL container

func CleanupTestData added in v0.3.0

func CleanupTestData(t *testing.T, db *gorm.DB)

CleanupTestData cleans up test data from the shared database

func GetSharedMySQLDB added in v0.3.0

func GetSharedMySQLDB(t *testing.T) (*gorm.DB, func())

GetSharedMySQLDB returns a connection to the shared MySQL database

func GetSharedMySQLDSN added in v0.3.0

func GetSharedMySQLDSN(t *testing.T) string

GetSharedMySQLDSN returns the DSN for the shared MySQL database

func SetupMySQLWithMigrations added in v0.3.0

func SetupMySQLWithMigrations(t *testing.T) (*gorm.DB, func())

SetupMySQLWithMigrations returns a migrated MySQL database connection

func SetupSharedMySQL added in v0.3.0

func SetupSharedMySQL() error

SetupSharedMySQL initializes a shared MySQL container for all tests

func TestMainHelper added in v0.3.0

func TestMainHelper(m *testing.M) int

TestMainHelper provides a helper function for package-level test setup

Types

This section is empty.

Jump to

Keyboard shortcuts

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