MCPcopy
hub / github.com/RoaringBitmap/roaring / TestBackwardCount

Function TestBackwardCount

iter_test.go:10–27  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

8)
9
10func TestBackwardCount(t *testing.T) {
11 array := []int{2, 63, 64, 65, 4095, 4096, 4097, 4159, 4160, 4161, 5000, 20000, 66666}
12 for _, testSize := range array {
13 b := New()
14 for i := uint32(0); i < uint32(testSize); i++ {
15 b.Add(i)
16 }
17 it := Values(b)
18
19 count := 0
20 it(func(_ uint32) bool {
21 count++
22 return true
23 })
24
25 assert.Equal(t, testSize, count)
26 }
27}
28
29func TestBackward(t *testing.T) {
30 t.Run("#1", func(t *testing.T) {

Callers

nothing calls this directly

Calls 3

NewFunction · 0.70
ValuesFunction · 0.70
AddMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…