database

package
v0.0.0-...-38e227c Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MustLoadEnv

func MustLoadEnv(path ...string)

MustLoadEnv try to load .env file from a path. If file does not exist, it will do nothing.

func MustNotEmptyString

func MustNotEmptyString(s string) string

MustNotEmptyString panics if the string is empty.

func SearchUpwardForFile

func SearchUpwardForFile(fileName string) string

SearchUpwardForFile searches for a file in the current directory and all parent directories.

Types

type DevDatabase

type DevDatabase struct {
	*sqlx.DB
	// contains filtered or unexported fields
}

func NewTestDatabase

func NewTestDatabase(databaseName string) *DevDatabase

func (*DevDatabase) Close

func (db *DevDatabase) Close(t Testing)

func (*DevDatabase) String

func (db *DevDatabase) String() string

type Testing

type Testing interface {
	Helper()
	Failed() bool
}

Jump to

Keyboard shortcuts

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