sqltest

package
v0.23.0 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package sqltest provides utilities for testing SQL databases.

Index

Constants

View Source
const (
	PostgresDSN = "postgres://postgres:secret@localhost:5432/zero-test?sslmode=disable"
)

Variables

This section is empty.

Functions

func NewForTesting

func NewForTesting(t *testing.T, dsn string, migrations zerosql.Migrations) (*sql.DB, zerosql.Driver)

NewForTesting creates a new database instance and driver for testing purposes.

It encapsulates the boilerplate around constructing a connection and driver.

Types

This section is empty.

Jump to

Keyboard shortcuts

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