@@ -10,7 +10,7 @@ import (
1010var readStringPoolTests = []struct {
1111 input []uint8
1212 strings []string
13- styles []string
13+ styles []ResStringPoolSpan
1414}{
1515 {
1616 []uint8 {
@@ -29,18 +29,20 @@ var readStringPoolTests = []struct {
2929
3030 // StyleIndexes
3131 0x00 , 0x00 , 0x00 , 0x00 ,
32- 0x04 , 0x00 , 0x00 , 0x00 ,
32+ 0x08 , 0x00 , 0x00 , 0x00 ,
3333
3434 // Strings
3535 0x01 , 0x00 , 0x61 , 0x00 ,
3636 0x01 , 0x00 , 0x42 , 0x30 ,
3737
3838 // Styles
39- 0x01 , 0x00 , 0x63 , 0x00 ,
40- 0x01 , 0x00 , 0x43 , 0x30 ,
39+ 0x01 , 0x00 , 0x00 , 0x00 ,
40+ 0x02 , 0x00 , 0x00 , 0x00 ,
41+ 0x03 , 0x00 , 0x00 , 0x00 ,
42+ 0x04 , 0x00 , 0x00 , 0x00 ,
4143 },
42- []string {"a" , "\304 2 " },
43- []string { "b" , " \304 3" },
44+ []string {"a" , "\u3042 " },
45+ []ResStringPoolSpan {{ 1 , 2 }, { 3 , 4 } },
4446 },
4547}
4648
@@ -52,10 +54,10 @@ func TestReadStringPool(t *testing.T) {
5254 if err != nil {
5355 t .Errorf ("got %v want no error" , err )
5456 }
55- if reflect .DeepEqual (actual .Strings , tt .strings ) {
57+ if ! reflect .DeepEqual (actual .Strings , tt .strings ) {
5658 t .Errorf ("got %v want %v" , actual .Strings , tt .strings )
5759 }
58- if reflect .DeepEqual (actual .Styles , tt .styles ) {
60+ if ! reflect .DeepEqual (actual .Styles , tt .styles ) {
5961 t .Errorf ("got %v want %v" , actual .Styles , tt .styles )
6062 }
6163 }
0 commit comments