mirror of
git://sourceware.org/git/glibc.git
synced 2024-11-21 01:12:26 +08:00
49891c1062
1997-10-09 04:56 Ulrich Drepper <drepper@cygnus.com> * locales/is_IS: Update from Debian version. 1997-08-29 03:16 Ulrich Drepper <drepper@cygnus.com> * tst-fmon.c: New file. strfmon test program. * tst-fmon.sh: New file. Script to run strfmon test. * fmon-de_DE.exp: New file. Expected result of strfmon test for de_DE. * fmon-en_US.exp: New file. Expected result of strfmon test for en_US. * locales/cs_CZ: Update from author.
135 lines
5.5 KiB
Plaintext
135 lines
5.5 KiB
Plaintext
# Test data for test-strfmon, which checks it's implementation in glibc
|
|
# Copyright (C) 1996, 1997 Free Software Foundation, Inc.
|
|
# This file is part of the GNU C Library.
|
|
# Contributed by Jochen Hein <jochen.hein@delphi.central.de>, 1997.
|
|
#
|
|
# The GNU C Library is free software; you can redistribute it and/or
|
|
# modify it under the terms of the GNU Library General Public License as
|
|
# published by the Free Software Foundation; either version 2 of the
|
|
# License, or (at your option) any later version.
|
|
#
|
|
# The GNU C Library is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
# Library General Public License for more details.
|
|
#
|
|
# You should have received a copy of the GNU Library General Public
|
|
# License along with the GNU C Library; see the file COPYING.LIB. If
|
|
# not, write to the Free Software Foundation, Inc.,
|
|
# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
|
# The format of this file is pretty simple: Each line contains a test
|
|
# for strfmon. Fields are seperated by TABs. Lines that start with a
|
|
# '#' are comments and are ignored.
|
|
#
|
|
# Field Deskription
|
|
# #1 locale which is to be checked
|
|
# #2 format string which is fed into strfmon
|
|
# #3 double value that is used for formatting
|
|
# #4 the expected result (may contain trailing spaces!)
|
|
#
|
|
# First the implementation without any locale-dependent data
|
|
# - no currency symbol is printed, formatting is somewhat standard
|
|
C %n 1.23 1.23
|
|
C %n -1.23 -1.23
|
|
C %n 0 0.00
|
|
C %% 0 %
|
|
C *%n* 1.23 * 1.23*
|
|
C %9n 1.23 1.23
|
|
C %#9n 1.23 1.23
|
|
C %=*#9n 1.23 ********1.23
|
|
#
|
|
# check both the german locale and strfmon with that data
|
|
#
|
|
de_DE.ISO-8859-1 %n 1.23 DM1,23
|
|
de_DE.ISO-8859-1 %n -1.23 -DM1,23
|
|
de_DE.ISO-8859-1 %n 1234.56 DM1.234,56
|
|
de_DE.ISO-8859-1 %11n 123.45 DM123,45
|
|
de_DE.ISO-8859-1 %11n -123.45 -DM123,45
|
|
de_DE.ISO-8859-1 %11n 3456.781 DM3.456,78
|
|
de_DE.ISO-8859-1 %^n 1234.56 DM1234,56
|
|
de_DE.ISO-8859-1 %+n 1234.56 DM1.234,56
|
|
de_DE.ISO-8859-1 %+n -1234.56 -DM1.234,56
|
|
# The following line ends with a blank
|
|
de_DE.ISO-8859-1 %(n 1234.56 DM1.234,56
|
|
de_DE.ISO-8859-1 %(n -1234.56 (DM1.234,56)
|
|
de_DE.ISO-8859-1 %^n 1234.56 DM1234,56
|
|
de_DE.ISO-8859-1 %i 1.23 DEM 1,23
|
|
de_DE.ISO-8859-1 %i -1.23 -DEM 1,23
|
|
de_DE.ISO-8859-1 %i 1234.56 DEM 1.234,56
|
|
de_DE.ISO-8859-1 %^i 1234.56 DEM 1234,56
|
|
de_DE.ISO-8859-1 %+i 1234.56 DEM 1.234,56
|
|
de_DE.ISO-8859-1 %+i -1234.56 -DEM 1.234,56
|
|
de_DE.ISO-8859-1 %(i 1234.56 DEM 1.234,56
|
|
de_DE.ISO-8859-1 %(i -1234.56 (DEM 1.234,56)
|
|
de_DE.ISO-8859-1 %^i 1234.56 DEM 1234,56
|
|
de_DE.ISO-8859-1 %#5n 123.45 DM 123,45
|
|
de_DE.ISO-8859-1 %#5n -123.45 -DM 123,45
|
|
de_DE.ISO-8859-1 %#5n 3456.781 DM 3.456,78
|
|
de_DE.ISO-8859-1 %=*#5n 123.45 DM***123,45
|
|
de_DE.ISO-8859-1 %=*#5n -123.45 -DM***123,45
|
|
de_DE.ISO-8859-1 %=*#5n 3456.781 DM*3.456,78
|
|
de_DE.ISO-8859-1 %=0#5n 123.45 DM000123,45
|
|
de_DE.ISO-8859-1 %=0#5n -123.45 -DM000123,45
|
|
de_DE.ISO-8859-1 %=0#5n 3456.781 DM03.456,78
|
|
de_DE.ISO-8859-1 %^#5n 123.45 DM 123,45
|
|
de_DE.ISO-8859-1 %^#5n -123.45 -DM 123,45
|
|
de_DE.ISO-8859-1 %^#5n 3456.781 DM 3456,78
|
|
de_DE.ISO-8859-1 %^#5.0n 123.45 DM 123
|
|
de_DE.ISO-8859-1 %^#5.0n -123.45 -DM 123
|
|
de_DE.ISO-8859-1 %^#5.0n 3456.781 DM 3457
|
|
de_DE.ISO-8859-1 %^#5.4n 123.45 DM 123,4500
|
|
de_DE.ISO-8859-1 %^#5.4n -123.45 -DM 123,4500
|
|
de_DE.ISO-8859-1 %^#5.4n 3456.781 DM 3456,7810
|
|
# This line is followed by a blank!
|
|
de_DE.ISO-8859-1 %(#5n 123.45 DM 123,45
|
|
de_DE.ISO-8859-1 %(#5n -123.45 (DM 123,45)
|
|
# This line is followed by a blank!
|
|
de_DE.ISO-8859-1 %(#5n 3456.781 DM 3.456,78
|
|
# This line is followed by a blank!
|
|
de_DE.ISO-8859-1 %!(#5n 123.45 123,45
|
|
de_DE.ISO-8859-1 %!(#5n -123.45 ( 123,45)
|
|
# This line is followed by a blank!
|
|
de_DE.ISO-8859-1 %!(#5n 3456.781 3.456,78
|
|
#
|
|
# check both the en_US locale and strfmon with that data
|
|
# a lot of this checks are created from a strfmon(3) man-page.
|
|
#
|
|
en_US.ISO-8859-1 %n 123.45 $123.45
|
|
en_US.ISO-8859-1 %n -123.45 -$123.45
|
|
en_US.ISO-8859-1 %n 3456.781 $3,456.78
|
|
en_US.ISO-8859-1 %i 123.45 USD 123.45
|
|
en_US.ISO-8859-1 %i -123.45 -USD 123.45
|
|
en_US.ISO-8859-1 %i 3456.781 USD 3,456.78
|
|
en_US.ISO-8859-1 %11n 123.45 $123.45
|
|
en_US.ISO-8859-1 %11n -123.45 -$123.45
|
|
en_US.ISO-8859-1 %11n 3456.781 $3,456.78
|
|
en_US.ISO-8859-1 %=*#5n 123.45 $***123.45
|
|
en_US.ISO-8859-1 %=*#5n -123.45 -$***123.45
|
|
en_US.ISO-8859-1 %=*#5n 3456.781 $*3,456.78
|
|
en_US.ISO-8859-1 %=0#5n 123.45 $000123.45
|
|
en_US.ISO-8859-1 %=0#5n -123.45 -$000123.45
|
|
en_US.ISO-8859-1 %=0#5n 3456.781 $03,456.78
|
|
en_US.ISO-8859-1 %^#5n 123.45 $ 123.45
|
|
en_US.ISO-8859-1 %^#5n -123.45 -$ 123.45
|
|
en_US.ISO-8859-1 %^#5n 3456.781 $ 3456.78
|
|
en_US.ISO-8859-1 %^#5.0n 123.45 $ 123
|
|
en_US.ISO-8859-1 %^#5.0n -123.45 -$ 123
|
|
en_US.ISO-8859-1 %^#5.0n 3456.781 $ 3457
|
|
en_US.ISO-8859-1 %^#5.4n 123.45 $ 123.4500
|
|
en_US.ISO-8859-1 %^#5.4n -123.45 -$ 123.4500
|
|
en_US.ISO-8859-1 %^#5.4n 3456.781 $ 3456.7810
|
|
# This line is followed by a blank!
|
|
en_US.ISO-8859-1 %(#5n 123.45 $ 123.45
|
|
en_US.ISO-8859-1 %(#5n -123.45 ($ 123.45)
|
|
# This line is followed by a blank!
|
|
en_US.ISO-8859-1 %(#5n 3456.781 $ 3,456.78
|
|
# This line is followed by a blank!
|
|
en_US.ISO-8859-1 %!(#5n 123.45 123.45
|
|
en_US.ISO-8859-1 %!(#5n -123.45 ( 123.45)
|
|
# This line is followed by a blank!
|
|
en_US.ISO-8859-1 %!(#5n 3456.781 3,456.78
|
|
en_US.ISO-8859-1 %#5n 123.45 $ 123.45
|
|
en_US.ISO-8859-1 %#5n -123.45 -$ 123.45
|
|
en_US.ISO-8859-1 %#5n 3456.781 $ 3,456.78
|