Skip to content

Commit 6b110b3

Browse files
committed
test(withoutempty): missing test
1 parent f1c3379 commit 6b110b3

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

intersect_test.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,9 +297,11 @@ func TestWithoutEmpty(t *testing.T) {
297297
result1 := WithoutEmpty([]int{0, 1, 2})
298298
result2 := WithoutEmpty([]int{1, 2})
299299
result3 := WithoutEmpty([]int{})
300+
result4 := WithoutEmpty([]*int{ToPtr(0), ToPtr(1), nil, ToPtr(2)})
300301
is.Equal(result1, []int{1, 2})
301302
is.Equal(result2, []int{1, 2})
302303
is.Equal(result3, []int{})
304+
is.Equal(result4, []*int{ToPtr(0), ToPtr(1), ToPtr(2)})
303305

304306
type myStrings []string
305307
allStrings := myStrings{"", "foo", "bar"}

0 commit comments

Comments
 (0)