testutil

package
v0.0.0-...-f7bad0d Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PrepareTxn

func PrepareTxn(t testing.TB, update bool) *badger.Txn

PrepareTxn creates an in-memory BadgerDB and a transaction for testing.

Types

type TestStruct

type TestStruct struct {
	A int            `json:"a,omitempty"`
	B string         `json:"b,omitempty"`
	C bool           `json:"c,omitempty"`
	D []int          `json:"d,omitempty"`
	E map[string]int `json:"e,omitempty"`
	F *TestStruct    `json:"f,omitempty"`
}

func (TestStruct) MarshalBinary

func (t TestStruct) MarshalBinary() ([]byte, error)

func (*TestStruct) UnmarshalBinary

func (t *TestStruct) UnmarshalBinary(data []byte) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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