mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-10-27 16:50:58 +01:00
22758: fix tests by setting locale to C
This commit is contained in:
parent
4fdf7ec7b7
commit
4e576c069c
4 changed files with 19 additions and 2 deletions
|
|
@ -1,3 +1,9 @@
|
||||||
|
2006-09-22 Andrey Borzenkov <bor@zsh.org>
|
||||||
|
|
||||||
|
* 22758: Test/A06assign.ztst, Test/B03print.ztst,
|
||||||
|
Test/E01options.ztst: force locale to C to avoid test failures
|
||||||
|
due to localized output
|
||||||
|
|
||||||
2006-09-21 Peter Stephenson <p.w.stephenson@ntlworld.com>
|
2006-09-21 Peter Stephenson <p.w.stephenson@ntlworld.com>
|
||||||
|
|
||||||
* 22752: + Roman Neuhauser: Doc/Zsh/compsys.yo,
|
* 22752: + Roman Neuhauser: Doc/Zsh/compsys.yo,
|
||||||
|
|
|
||||||
|
|
@ -55,6 +55,13 @@
|
||||||
(( i == 30 ))
|
(( i == 30 ))
|
||||||
0:add to integer
|
0:add to integer
|
||||||
|
|
||||||
|
# According to official printf info page:
|
||||||
|
# A floating-point argument must use a period before any fractional
|
||||||
|
# digits, but is printed according to the `LC_NUMERIC' category of the
|
||||||
|
# current locale.
|
||||||
|
# So, force LC_ALL to be C (otherwise it overrides LC_NUMERIC)
|
||||||
|
|
||||||
|
LC_ALL=C LC_NUMERIC=C
|
||||||
float f=3.4
|
float f=3.4
|
||||||
f+=2.3
|
f+=2.3
|
||||||
printf "%g\n" f
|
printf "%g\n" f
|
||||||
|
|
|
||||||
|
|
@ -76,6 +76,8 @@
|
||||||
>123 678
|
>123 678
|
||||||
>90 0
|
>90 0
|
||||||
|
|
||||||
|
# See A06assign for full explanation
|
||||||
|
LC_ALL=C LC_NUMERIC=C
|
||||||
printf '%g %g\n' 123.45 678 90.1
|
printf '%g %g\n' 123.45 678 90.1
|
||||||
0:test g format specifier
|
0:test g format specifier
|
||||||
>123.45 678
|
>123.45 678
|
||||||
|
|
|
||||||
|
|
@ -195,6 +195,8 @@
|
||||||
>8#21
|
>8#21
|
||||||
>023
|
>023
|
||||||
|
|
||||||
|
# now-a-days cd can easily be localized. Force default (POSIX) locale
|
||||||
|
LC_ALL=C LC_MESSAGES=C
|
||||||
setopt cdablevars
|
setopt cdablevars
|
||||||
# only absolute paths are eligible for ~-expansion
|
# only absolute paths are eligible for ~-expansion
|
||||||
cdablevar1=tmpcd
|
cdablevar1=tmpcd
|
||||||
|
|
@ -207,8 +209,8 @@
|
||||||
cd cdablevar2
|
cd cdablevar2
|
||||||
1q:CDABLE_VARS option
|
1q:CDABLE_VARS option
|
||||||
>back in options.tmp
|
>back in options.tmp
|
||||||
?(eval):cd:4: no such file or directory: cdablevar1
|
?(eval):cd:6: no such file or directory: cdablevar1
|
||||||
?(eval):cd:10: no such file or directory: cdablevar2
|
?(eval):cd:12: no such file or directory: cdablevar2
|
||||||
|
|
||||||
# CHASE_DOTS should go with CHASE_LINKS in B01cd.ztst
|
# CHASE_DOTS should go with CHASE_LINKS in B01cd.ztst
|
||||||
# which saves me having to write it here.
|
# which saves me having to write it here.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue