dbtest

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2023 License: Apache-2.0 Imports: 10 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertDomain

func AssertDomain(t *testing.T, itr dbm.Iterator, start, end []byte)

func AssertInvalid

func AssertInvalid(t *testing.T, itr dbm.Iterator)

func AssertItem

func AssertItem(t *testing.T, itr dbm.Iterator, key, value []byte)

func AssertKeyPanics

func AssertKeyPanics(t *testing.T, itr dbm.Iterator)

func AssertNext

func AssertNext(t *testing.T, itr dbm.Iterator, expected bool)

func AssertValue

func AssertValue(t *testing.T, db dbm.DBReader, key, valueWanted []byte)

func AssertValuePanics

func AssertValuePanics(t *testing.T, itr dbm.Iterator)

func BenchmarkRandomReadsWrites

func BenchmarkRandomReadsWrites(b *testing.B, db dbm.DBReadWriter)

func BenchmarkRangeScans

func BenchmarkRangeScans(b *testing.B, db dbm.DBReadWriter, dbSize int64)

func BytesToInt64

func BytesToInt64(buf []byte) int64

func DoTestGetSetHasDelete

func DoTestGetSetHasDelete(t *testing.T, load Loader)

func DoTestIterators

func DoTestIterators(t *testing.T, load Loader)

func DoTestReloadDB

func DoTestReloadDB(t *testing.T, load Loader)

Tests reloading a saved DB from disk.

func DoTestRevert

func DoTestRevert(t *testing.T, load Loader, reload bool)

Test that Revert works as intended, optionally closing and reloading the DB both before and after reverting

func DoTestTransactions

func DoTestTransactions(t *testing.T, load Loader, multipleWriters bool)

func DoTestVersioning

func DoTestVersioning(t *testing.T, load Loader)

func Int64ToBytes

func Int64ToBytes(i int64) []byte

Types

type Loader

type Loader func(*testing.T, string) dbm.DBConnection

Jump to

Keyboard shortcuts

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