MCPcopy
hub / github.com/minio/minio-go / TestIntSetUnion

Function TestIntSetUnion

pkg/set/set_test.go:108–117  ·  view source on GitHub ↗

Test Union()

(t *testing.T)

Source from the content-addressed store, hash-verified

106
107// Test Union()
108func TestIntSetUnion(t *testing.T) {
109 s1 := Create(1, 2, 3)
110 s2 := Create(3, 4, 5)
111 result := s1.Union(s2)
112
113 expected := Create(1, 2, 3, 4, 5)
114 if !result.Equals(expected) {
115 t.Fatalf("expected union {1, 2, 3, 4, 5}, got: %v", result)
116 }
117}
118
119// Test Copy()
120func TestIntSetCopy(t *testing.T) {

Callers

nothing calls this directly

Calls 3

CreateFunction · 0.85
UnionMethod · 0.45
EqualsMethod · 0.45

Tested by

no test coverage detected