psqltest

package module
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package psqltest is a similar package to net/http/http test This package provides utilities for testing psql services.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewTransactionDB

func NewTransactionDB(dsn string) (*sql.DB, error)

NewTransactionDB returns a new transaction DB connection.

func NewTransactionTestingDB

func NewTransactionTestingDB(t *testing.T) *sql.DB

NewTransactionTestingDB returns a new transaction DB connection. It acts as a test helper and also takes care of closing the db.

func Register

func Register(dsn string)

Register is a wrapper over txdb.Register. Used to register the txdb driver.

func YamlPollute

func YamlPollute(yamlReader io.Reader, db *sql.DB) error

YamlPollute is a function to insert data in a database based on a YAML.

Types

This section is empty.

Jump to

Keyboard shortcuts

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