MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / TestKVIPList_ReadItems

Function TestKVIPList_ReadItems

internal/iplibrary/ip_list_kv_test.go:165–185  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

163}
164
165func TestKVIPList_ReadItems(t *testing.T) {
166 kv, err := iplibrary.NewKVIPList()
167 if err != nil {
168 t.Fatal(err)
169 }
170
171 for {
172 items, goNext, readErr := kv.ReadItems(0, 2)
173 if readErr != nil {
174 t.Fatal(readErr)
175 }
176 t.Log("====")
177 for _, item := range items {
178 t.Log(item.Id)
179 }
180
181 if !goNext {
182 break
183 }
184 }
185}
186
187func TestKVIPList_CountItems(t *testing.T) {
188 kv, err := iplibrary.NewKVIPList()

Callers

nothing calls this directly

Calls 3

ReadItemsMethod · 0.95
NewKVIPListFunction · 0.92
LogMethod · 0.80

Tested by

no test coverage detected