MCPcopy
hub / github.com/dgraph-io/badger / TestSimpleIterator

Function TestSimpleIterator

table/merge_iterator_test.go:117–127  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

115}
116
117func TestSimpleIterator(t *testing.T) {
118 keys := []string{"1", "2", "3"}
119 vals := []string{"v1", "v2", "v3"}
120 it := newSimpleIterator(keys, vals, false)
121 it.Rewind()
122 k, v := getAll(it)
123 require.EqualValues(t, keys, k)
124 require.EqualValues(t, vals, v)
125
126 closeAndCheck(t, it, 1)
127}
128
129func reversed(a []string) []string {
130 var out []string

Callers

nothing calls this directly

Calls 4

newSimpleIteratorFunction · 0.85
getAllFunction · 0.85
closeAndCheckFunction · 0.85
RewindMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…