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

Function TestNewPartialRanges2

internal/caches/partial_ranges_test.go:50–64  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

48}
49
50func TestNewPartialRanges2(t *testing.T) {
51 // low -> high
52 var r = caches.NewPartialRanges(0)
53 r.Add(1, 100)
54 r.Add(1, 101)
55 r.Add(1, 102)
56 r.Add(2, 103)
57 r.Add(200, 300)
58 r.Add(301, 302)
59 r.Add(303, 304)
60 r.Add(250, 400)
61
62 var rs = r.Ranges
63 logs.PrintAsJSON(rs, t)
64}
65
66func TestNewPartialRanges3(t *testing.T) {
67 // high -> low

Callers

nothing calls this directly

Calls 2

NewPartialRangesFunction · 0.92
AddMethod · 0.65

Tested by

no test coverage detected