dstest

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2021 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

BasicSubtests is a list of all basic tests.

BatchSubtests is a list of all basic batching datastore tests.

View Source
var ElemCount = 100

ElemCount sets with how many elements the datastore suit tests are usually run with. Best to set to round numbers like 20, 30, 40... and at least to 20.

View Source
var ErrTest = errors.New("test error")

Functions

func Err

func Err(err error, t *testing.T, msgs ...string)

func False

func False(v bool, t *testing.T, msgs ...string)

func NewMapDatastoreForTest

func NewMapDatastoreForTest(t *testing.T, ktype key.KeyType) *dstore.MapDatastore

func NewTestDatastore

func NewTestDatastore(ktype key.KeyType, testErrors bool) *testDatastore

func Nil

func Nil(err error, t *testing.T, msgs ...string)

func RunBatchDeleteTest

func RunBatchDeleteTest(t *testing.T, ktype key.KeyType, ds dstore.Batching)

func RunBatchPutAndDeleteTest

func RunBatchPutAndDeleteTest(t *testing.T, ktype key.KeyType, ds dstore.Batching)

func RunBatchTest

func RunBatchTest(t *testing.T, ktype key.KeyType, ds dstore.Batching)

func SubtestAll

func SubtestAll(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

SubtestAll tests the given datastore against all the subtests.

func SubtestBasicPutGet

func SubtestBasicPutGet(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func SubtestBasicSync

func SubtestBasicSync(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func SubtestCombinations

func SubtestCombinations(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func SubtestFilter

func SubtestFilter(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func SubtestLimit

func SubtestLimit(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func SubtestManyKeysAndQuery

func SubtestManyKeysAndQuery(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func SubtestNotFounds

func SubtestNotFounds(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func SubtestOrder

func SubtestOrder(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func SubtestPrefix

func SubtestPrefix(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func SubtestReturnSizes

func SubtestReturnSizes(t *testing.T, ktype key.KeyType, ds dstore.Datastore)

func TestElemCount

func TestElemCount(t *testing.T)

func True

func True(v bool, t *testing.T, msgs ...string)

Types

This section is empty.

Jump to

Keyboard shortcuts

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