@@ -91,8 +91,8 @@ func TestUnmarshalToMap(t *testing.T) {
91
91
{`a = "b"` , TOML , expect },
92
92
{`a: "b"` , YAML , expect },
93
93
// Make sure we get all string keys, even for YAML
94
- {"a: Easy!\n b:\n c: 2\n d: [3, 4]" , YAML , map [string ]any {"a" : "Easy!" , "b" : map [string ]any {"c" : 2 , "d" : []any {3 , 4 }}}},
95
- {"a:\n true: 1\n false: 2" , YAML , map [string ]any {"a" : map [string ]any {"true" : 1 , "false" : 2 }}},
94
+ {"a: Easy!\n b:\n c: 2\n d: [3, 4]" , YAML , map [string ]any {"a" : "Easy!" , "b" : map [string ]any {"c" : uint64 ( 2 ) , "d" : []any {uint64 ( 3 ), uint64 ( 4 ) }}}},
95
+ {"a:\n true: 1\n false: 2" , YAML , map [string ]any {"a" : map [string ]any {"true" : uint64 ( 1 ) , "false" : uint64 ( 2 ) }}},
96
96
{`{ "a": "b" }` , JSON , expect },
97
97
{`<root><a>b</a></root>` , XML , expect },
98
98
{`#+a: b` , ORG , expect },
@@ -137,7 +137,7 @@ func TestUnmarshalToInterface(t *testing.T) {
137
137
{[]byte (`a: "b"` ), YAML , expect },
138
138
{[]byte (`<root><a>b</a></root>` ), XML , expect },
139
139
{[]byte (`a,b,c` ), CSV , [][]string {{"a" , "b" , "c" }}},
140
- {[]byte ("a: Easy!\n b:\n c: 2\n d: [3, 4]" ), YAML , map [string ]any {"a" : "Easy!" , "b" : map [string ]any {"c" : 2 , "d" : []any {3 , 4 }}}},
140
+ {[]byte ("a: Easy!\n b:\n c: 2\n d: [3, 4]" ), YAML , map [string ]any {"a" : "Easy!" , "b" : map [string ]any {"c" : uint64 ( 2 ) , "d" : []any {uint64 ( 3 ), uint64 ( 4 ) }}}},
141
141
// errors
142
142
{[]byte (`a = "` ), TOML , false },
143
143
} {
@@ -170,7 +170,7 @@ func TestUnmarshalStringTo(t *testing.T) {
170
170
{"32" , int64 (1234 ), int64 (32 )},
171
171
{"32" , int (1234 ), int (32 )},
172
172
{"3.14159" , float64 (1 ), float64 (3.14159 )},
173
- {"[3,7,9]" , []any {}, []any {3 , 7 , 9 }},
173
+ {"[3,7,9]" , []any {}, []any {uint64 ( 3 ), uint64 ( 7 ), uint64 ( 9 ) }},
174
174
{"[3.1,7.2,9.3]" , []any {}, []any {3.1 , 7.2 , 9.3 }},
175
175
} {
176
176
msg := qt .Commentf ("%d: %T" , i , test .to )
0 commit comments