Avoid locale-dependent output in numericlocale check.
I'd forgotten that in the buildfarm, parts of the regression tests may run with psql exposed to a non-default LC_NUMERIC setting. Hence we can't assume that C locale prevails, nor is there any accessible way to force the setting for this single test step. Lobotomize the test case added by commit 9a98984f4 so that it covers as much as we can of print.c without having any locale-varying output.
This commit is contained in:
parent
67ed3b9d73
commit
95dcb8fc05
@ -2773,18 +2773,18 @@ Argument data types | numeric
|
||||
Type | func
|
||||
|
||||
\pset tuples_only false
|
||||
-- test numericlocale (not too interesting in C locale, but ...)
|
||||
-- test numericlocale (as best we can without control of psql's locale)
|
||||
\pset format aligned
|
||||
\pset expanded off
|
||||
\pset numericlocale true
|
||||
select n, -n as m, n * 1000 + 111.1111 as x, '1e90'::float8 as f
|
||||
select n, -n as m, n * 111 as x, '1e90'::float8 as f
|
||||
from generate_series(0,3) n;
|
||||
n | m | x | f
|
||||
---+----+------------+-------
|
||||
0 | 0 | 111.1111 | 1e+90
|
||||
1 | -1 | 1,111.1111 | 1e+90
|
||||
2 | -2 | 2,111.1111 | 1e+90
|
||||
3 | -3 | 3,111.1111 | 1e+90
|
||||
n | m | x | f
|
||||
---+----+-----+-------
|
||||
0 | 0 | 0 | 1e+90
|
||||
1 | -1 | 111 | 1e+90
|
||||
2 | -2 | 222 | 1e+90
|
||||
3 | -3 | 333 | 1e+90
|
||||
(4 rows)
|
||||
|
||||
\pset numericlocale false
|
||||
|
@ -448,13 +448,13 @@ select 1 where false;
|
||||
\df exp
|
||||
\pset tuples_only false
|
||||
|
||||
-- test numericlocale (not too interesting in C locale, but ...)
|
||||
-- test numericlocale (as best we can without control of psql's locale)
|
||||
|
||||
\pset format aligned
|
||||
\pset expanded off
|
||||
\pset numericlocale true
|
||||
|
||||
select n, -n as m, n * 1000 + 111.1111 as x, '1e90'::float8 as f
|
||||
select n, -n as m, n * 111 as x, '1e90'::float8 as f
|
||||
from generate_series(0,3) n;
|
||||
|
||||
\pset numericlocale false
|
||||
|
Loading…
x
Reference in New Issue
Block a user