MCPcopy
hub / github.com/dgraph-io/dgraph / listToArray

Function listToArray

posting/list_test.go:57–64  ·  view source on GitHub ↗
(t *testing.T, afterUid uint64, l *List, readTs uint64)

Source from the content-addressed store, hash-verified

55}
56
57func listToArray(t *testing.T, afterUid uint64, l *List, readTs uint64) []uint64 {
58 out := make([]uint64, 0, 10)
59 require.NoError(t, l.Iterate(readTs, afterUid, func(p *pb.Posting) error {
60 out = append(out, p.Uid)
61 return nil
62 }))
63 return out
64}
65
66func checkUids(t *testing.T, l *List, uids []uint64, readTs uint64) {
67 require.Equal(t, uids, listToArray(t, 0, l, readTs))

Callers 3

checkUidsFunction · 0.85
TestAddMutationFunction · 0.85
TestAddMutation_gru2Function · 0.85

Calls 1

IterateMethod · 0.45

Tested by

no test coverage detected