testutil

package
v0.0.0-...-17277e5 Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDB

func NewDB(t *testing.T, r copydb.Redis, opts ...copydb.DBOpt) *copydb.DB

NewDB creates a new database instance.

func NewRedis

func NewRedis(t *testing.T) copydb.Redis

NewRedis returns a client connected to standalone Redis.

func ServeDB

func ServeDB(t *testing.T, db *copydb.DB)

ServeDB runs a database.

func StopDB

func StopDB(t *testing.T, db *copydb.DB, timeout time.Duration)

StopDB terminates a database.

func WaitForError

func WaitForError(d time.Duration, db *copydb.DB, id string, unix int64) error

WaitForError waits until an error will be returned.

func WaitForItem

func WaitForItem(d time.Duration, db *copydb.DB, id string, unix int64, resolve ...copydb.QueryResolve) error

WaitForItem waits until an identifier will be found in the database.

Types

This section is empty.

Jump to

Keyboard shortcuts

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