testutils

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2024 License: GPL-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetTestDB

func GetTestDB(ctx context.Context, t *testing.T) *database.DB

GetTestDB retrieves the database config from env variables, opens a new database and returns it.

The test suite will be skipped if no environment variable is set, otherwise fails fatally when invalid configurations are specified.

func MakeRandomString

func MakeRandomString(t *testing.T) string

MakeRandomString returns a 20 byte random hex string.

Types

This section is empty.

Jump to

Keyboard shortcuts

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