@@ -1202,19 +1202,19 @@ func TestSubsetNotSubset(t *testing.T) {
12021202 }{
12031203 // cases that are expected to contain
12041204 {[]int {1 , 2 , 3 }, nil , true , `nil is the empty set which is a subset of every set` },
1205- {[]int {1 , 2 , 3 }, []int {}, true , `[]int{} is a subset of []int{1, 2, 3} ` },
1206- {[]int {1 , 2 , 3 }, []int {1 , 2 }, true , `[]int{1, 2} is a subset of []int{1, 2, 3} ` },
1207- {[]int {1 , 2 , 3 }, []int {1 , 2 , 3 }, true , `[]int{1, 2, 3} is a subset of []int{1, 2, 3} ` },
1208- {[]string {"hello" , "world" }, []string {"hello" }, true , `[]string{ "hello"} is a subset of []string{ "hello", "world"} ` },
1205+ {[]int {1 , 2 , 3 }, []int {}, true , `[] is a subset of ['\x01' '\x02' '\x03'] ` },
1206+ {[]int {1 , 2 , 3 }, []int {1 , 2 }, true , `['\x01' '\x02'] is a subset of ['\x01' '\x02' '\x03'] ` },
1207+ {[]int {1 , 2 , 3 }, []int {1 , 2 , 3 }, true , `['\x01' '\x02' '\x03'] is a subset of ['\x01' '\x02' '\x03'] ` },
1208+ {[]string {"hello" , "world" }, []string {"hello" }, true , `["hello"] is a subset of ["hello" "world"] ` },
12091209 {map [string ]string {
12101210 "a" : "x" ,
12111211 "c" : "z" ,
12121212 "b" : "y" ,
12131213 }, map [string ]string {
12141214 "a" : "x" ,
12151215 "b" : "y" ,
1216- }, true , `map[string]string{ "a":"x", "b":"y"} is a subset of map[string]string{ "a":"x", "b":"y", "c":"z"} ` },
1217- {[]string {"a" , "b" , "c" }, map [string ]int {"a" : 1 , "c" : 3 }, true , `map[string]int{ "a":1, "c":3} is a subset of []string{ "a", "b", "c"} ` },
1216+ }, true , `map["a":"x" "b":"y"] is a subset of map["a":"x" "b":"y" "c":"z"] ` },
1217+ {[]string {"a" , "b" , "c" }, map [string ]int {"a" : 1 , "c" : 3 }, true , `map["a":'\x01' "c":'\x03'] is a subset of ["a" "b" "c"] ` },
12181218
12191219 // cases that are expected not to contain
12201220 {[]string {"hello" , "world" }, []string {"hello" , "testify" }, false , `[]string{"hello", "world"} does not contain "testify"` },
@@ -4032,19 +4032,19 @@ func TestNotSubsetWithSliceTooLongToPrint(t *testing.T) {
40324032 NotSubset (mockT , longSlice , longSlice )
40334033 Contains (t , mockT .errorString (), `
40344034 Error Trace:
4035- Error: []int{0, 0, 0, ` )
4036- Contains (t , mockT .errorString (), `<... truncated> is a subset of []int{0, 0, 0, ` )
4035+ Error: ['\x00' '\x00' '\x00' ` )
4036+ Contains (t , mockT .errorString (), `<... truncated> is a subset of ['\x00' '\x00' '\x00' ` )
40374037}
40384038
40394039func TestNotSubsetWithMapTooLongToPrint (t * testing.T ) {
40404040 t .Parallel ()
40414041 mockT := new (mockTestingT )
40424042 longSlice := make ([]int , 1_000_000 )
4043- NotSubset (mockT , map [bool ][]int {true : longSlice }, map [bool ][]int {true : longSlice })
4043+ NotSubset (mockT , map [int ][]int {1 : longSlice }, map [int ][]int {1 : longSlice })
40444044 Contains (t , mockT .errorString (), `
40454045 Error Trace:
4046- Error: map[bool][]int{true:[]int{0, 0, 0, ` )
4047- Contains (t , mockT .errorString (), `<... truncated> is a subset of map[bool][]int{true:[]int{0, 0, 0, ` )
4046+ Error: map['\x01':['\x00' '\x00' '\x00' ` )
4047+ Contains (t , mockT .errorString (), `<... truncated> is a subset of map['\x01':['\x00' '\x00' '\x00' ` )
40484048}
40494049
40504050func TestSameWithSliceTooLongToPrint (t * testing.T ) {
0 commit comments