MCPcopy Create free account
hub / github.com/Soft/iter / TestDrop

Function TestDrop

iterator_test.go:78–85  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

76}
77
78func TestDrop(t *testing.T) {
79 slice1 := ToSlice(Drop(Slice([]int{1, 2, 3, 4, 5}), 3))
80 equals(t, slice1, []int{4, 5})
81 slice2 := ToSlice(Drop(Slice([]int{1, 2, 3, 4, 5}), 0))
82 equals(t, slice2, []int{1, 2, 3, 4, 5})
83 slice3 := ToSlice(Drop(Slice([]int{1, 2, 3, 4, 5}), 5))
84 equals(t, slice3, []int{})
85}
86
87func TestDropWhile(t *testing.T) {
88 slice := ToSlice(

Callers

nothing calls this directly

Calls 4

ToSliceFunction · 0.85
DropFunction · 0.85
SliceFunction · 0.85
equalsFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…