Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit affec5a

Browse files
committed
fix tests. Current postgres check requires UTF8 locale :(
1 parent 28c70b7 commit affec5a

File tree

1 file changed

+20
-20
lines changed

1 file changed

+20
-20
lines changed

src/test/regress/expected/jsonb.out

+20-20
Original file line numberDiff line numberDiff line change
@@ -75,11 +75,11 @@ CONTEXT: JSON data, line 1: ...
7575
-- use octet_length here so we don't get an odd unicode char in the
7676
-- output
7777
SELECT octet_length('"\uaBcD"'::jsonb::text); -- OK, uppercase and lower case both OK
78-
ERROR: unsupported Unicode escape sequence
79-
LINE 1: SELECT octet_length('"\uaBcD"'::jsonb::text);
80-
^
81-
DETAIL: Unicode escape values cannot be used for code point values above 007F when the server encoding is not UTF8.
82-
CONTEXT: JSON data, line 1: ...
78+
octet_length
79+
--------------
80+
5
81+
(1 row)
82+
8383
-- Numbers.
8484
SELECT '1'::jsonb; -- OK
8585
jsonb
@@ -1957,11 +1957,11 @@ SELECT * FROM jsonb_populate_recordset(row('def',99,NULL)::jbpop,'[{"a":[100,200
19571957

19581958
-- handling of unicode surrogate pairs
19591959
SELECT octet_length((jsonb '{ "a": "\ud83d\ude04\ud83d\udc36" }' -> 'a')::text) AS correct_in_utf8;
1960-
ERROR: unsupported Unicode escape sequence
1961-
LINE 1: SELECT octet_length((jsonb '{ "a": "\ud83d\ude04\ud83d\udc3...
1962-
^
1963-
DETAIL: Unicode escape values cannot be used for code point values above 007F when the server encoding is not UTF8.
1964-
CONTEXT: JSON data, line 1: { "a":...
1960+
correct_in_utf8
1961+
-----------------
1962+
10
1963+
(1 row)
1964+
19651965
SELECT jsonb '{ "a": "\ud83d\ud83d" }' -> 'a'; -- 2 high surrogates in a row
19661966
ERROR: invalid input syntax for type json
19671967
LINE 1: SELECT jsonb '{ "a": "\ud83d\ud83d" }' -> 'a';
@@ -1988,11 +1988,11 @@ DETAIL: Unicode low surrogate must follow a high surrogate.
19881988
CONTEXT: JSON data, line 1: { "a":...
19891989
-- handling of simple unicode escapes
19901990
SELECT jsonb '{ "a": "the Copyright \u00a9 sign" }' as correct_in_utf8;
1991-
ERROR: unsupported Unicode escape sequence
1992-
LINE 1: SELECT jsonb '{ "a": "the Copyright \u00a9 sign" }' as corr...
1993-
^
1994-
DETAIL: Unicode escape values cannot be used for code point values above 007F when the server encoding is not UTF8.
1995-
CONTEXT: JSON data, line 1: { "a":...
1991+
correct_in_utf8
1992+
-------------------------------
1993+
{"a": "the Copyright © sign"}
1994+
(1 row)
1995+
19961996
SELECT jsonb '{ "a": "dollar \u0024 character" }' as correct_everywhere;
19971997
correct_everywhere
19981998
-----------------------------
@@ -2018,11 +2018,11 @@ SELECT jsonb '{ "a": "null \\u0000 escape" }' as not_an_escape;
20182018
(1 row)
20192019

20202020
SELECT jsonb '{ "a": "the Copyright \u00a9 sign" }' ->> 'a' as correct_in_utf8;
2021-
ERROR: unsupported Unicode escape sequence
2022-
LINE 1: SELECT jsonb '{ "a": "the Copyright \u00a9 sign" }' ->> 'a'...
2023-
^
2024-
DETAIL: Unicode escape values cannot be used for code point values above 007F when the server encoding is not UTF8.
2025-
CONTEXT: JSON data, line 1: { "a":...
2021+
correct_in_utf8
2022+
----------------------
2023+
the Copyright © sign
2024+
(1 row)
2025+
20262026
SELECT jsonb '{ "a": "dollar \u0024 character" }' ->> 'a' as correct_everywhere;
20272027
correct_everywhere
20282028
--------------------

0 commit comments

Comments
 (0)