Skip to content

Commit 4d3d99f

Browse files
committed
Fix TestJSONMapInconsistentComplexMap
1 parent 2af140f commit 4d3d99f

File tree

1 file changed

+10
-74
lines changed

1 file changed

+10
-74
lines changed

tests/json_test.go

+10-74
Original file line numberDiff line numberDiff line change
@@ -1014,70 +1014,6 @@ func TestJSONMapInconsistentComplexMap(t *testing.T) {
10141014
},
10151015
},
10161016
},
1017-
{
1018-
"e": map[string]any{
1019-
"f": "g",
1020-
"h": map[string]any{
1021-
"i": "j",
1022-
},
1023-
},
1024-
"k": Login{
1025-
IP: "85.242.48.167",
1026-
Row: 4,
1027-
Details: []map[string]any{
1028-
{
1029-
"src_port": uint64(232323),
1030-
"dest_port": uint64(10000),
1031-
},
1032-
{
1033-
"dest_port": uint64(7000),
1034-
"proxy_port": uint64(4080),
1035-
},
1036-
{
1037-
"server_port": uint64(7000),
1038-
"local_port": uint64(132323),
1039-
},
1040-
},
1041-
},
1042-
},
1043-
{
1044-
"g": Login{
1045-
IP: "85.242.48.167",
1046-
Row: 4,
1047-
Details: []map[string]any{
1048-
{
1049-
"src_port": uint64(232323),
1050-
"dest_port": uint64(9000),
1051-
},
1052-
{
1053-
"dest_port": uint64(8000),
1054-
"proxy_port": uint64(8080),
1055-
},
1056-
{
1057-
"server_port": uint64(8000),
1058-
"local_port": uint64(232323),
1059-
},
1060-
},
1061-
},
1062-
"m": []map[string]any{
1063-
{
1064-
"g": Login{
1065-
IP: "22.242.48.167",
1066-
Row: 4,
1067-
Details: []map[string]any{
1068-
{
1069-
"src_port": uint64(132323),
1070-
"dest_port": uint64(20000),
1071-
"local_port": uint64(132323),
1072-
},
1073-
{
1074-
"server_port": uint64(8000),
1075-
},
1076-
},
1077-
},
1078-
},
1079-
},
1080-
},
10811017
},
10821018
}
10831019
require.NoError(t, batch.Append(logins))
@@ -2386,16 +2322,16 @@ func TestJSONEscapeKeys(t *testing.T) {
23862322
ctx := context.Background()
23872323
batch := prepareBatch(t, conn, ctx)
23882324
row1 := map[string][]int64{
2389-
"56": {1, 2, 3},
2390-
"1.1": {4, 5, 6},
2391-
"世界世界世界": {7, 8, 9},
2392-
"1.1a": {10, 11, 12},
2393-
"a22.2": {13, 14, 15},
2394-
"a22`": {16, 17, 18},
2395-
"22.2`": {19, 20, 21},
2396-
"22.2\\`": {22, 23, 24},
2397-
"s'": {22, 23, 24},
2398-
"a`a\\\\": {22, 23, 24},
2325+
"56": {1, 2, 3},
2326+
"1.1": {4, 5, 6},
2327+
"世界世界世界": {7, 8, 9},
2328+
"1.1a": {10, 11, 12},
2329+
"a22.2": {13, 14, 15},
2330+
"a22`": {16, 17, 18},
2331+
"22.2`": {19, 20, 21},
2332+
"22.2\\`": {22, 23, 24},
2333+
"s'": {22, 23, 24},
2334+
"a`a\\\\": {22, 23, 24},
23992335
}
24002336
require.NoError(t, batch.Append(row1))
24012337
require.NoError(t, batch.Send())

0 commit comments

Comments
 (0)