summaryrefslogtreecommitdiffstats
path: root/tests/auto/corelib/tools/qlocale/tst_qlocale.cpp
diff options
context:
space:
mode:
authorEdward Welbourne <edward.welbourne@qt.io>2018-08-10 15:11:30 +0200
committerEdward Welbourne <edward.welbourne@qt.io>2018-08-13 16:17:53 +0000
commit44b6757fe50b6bf581864d3da519a3ff60818fa8 (patch)
tree2a3407a6de781c63112b18176b4d510c56311f5b /tests/auto/corelib/tools/qlocale/tst_qlocale.cpp
parentfd38c97a6c5b7bfab39b5f814d68a02e4d197e70 (diff)
Add support for numbered territories in CLDR
The CLDR data contains eight locales with numeric territory codes, 001 for World, 150 for Europe and 419 for Latin America. The last was already known in our enumdata.py, but as "Latin America and The Caribbean", which is not supported by the CLDR, so I've amended it while adding the other two. This gives us support for Esperanto and Yiddish (among others). [ChangeLog][QtCore][QLocale] Added support for World and Europe as (numeric) "country" codes ("territory" in CLDR terms), thereby enabling support for Yiddish and Esperanto, among other locales using such codes. Task-number: QTBUG-57802 Change-Id: Ibb1180fb720743a3a0589527649d10f3c9cd123d Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'tests/auto/corelib/tools/qlocale/tst_qlocale.cpp')
-rw-r--r--tests/auto/corelib/tools/qlocale/tst_qlocale.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/tests/auto/corelib/tools/qlocale/tst_qlocale.cpp b/tests/auto/corelib/tools/qlocale/tst_qlocale.cpp
index d649e66158..7efcd14d33 100644
--- a/tests/auto/corelib/tools/qlocale/tst_qlocale.cpp
+++ b/tests/auto/corelib/tools/qlocale/tst_qlocale.cpp
@@ -299,8 +299,8 @@ void tst_QLocale::defaulted_ctor()
TEST_CTOR(French, France, QLocale::French, QLocale::France)
TEST_CTOR(C, France, QLocale::C, QLocale::AnyCountry)
- TEST_CTOR(Spanish, LatinAmericaAndTheCaribbean, QLocale::Spanish,
- QLocale::LatinAmericaAndTheCaribbean)
+ TEST_CTOR(Spanish, LatinAmerica, QLocale::Spanish,
+ QLocale::LatinAmerica)
QLocale::setDefault(QLocale(QLocale::English, QLocale::France));
@@ -428,6 +428,8 @@ void tst_QLocale::defaulted_ctor()
TEST_CTOR("en_GB@bla", English, UnitedKingdom)
TEST_CTOR("en-GB", English, UnitedKingdom)
TEST_CTOR("en-GB@bla", English, UnitedKingdom)
+ TEST_CTOR("eo", Esperanto, World)
+ TEST_CTOR("yi", Yiddish, World)
QVERIFY(QLocale::Norwegian == QLocale::NorwegianBokmal);
TEST_CTOR("no", Norwegian, Norway)
@@ -437,8 +439,8 @@ void tst_QLocale::defaulted_ctor()
TEST_CTOR("nb_NO", Norwegian, Norway)
TEST_CTOR("nn_NO", NorwegianNynorsk, Norway)
TEST_CTOR("es_ES", Spanish, Spain)
- TEST_CTOR("es_419", Spanish, LatinAmericaAndTheCaribbean)
- TEST_CTOR("es-419", Spanish, LatinAmericaAndTheCaribbean)
+ TEST_CTOR("es_419", Spanish, LatinAmerica)
+ TEST_CTOR("es-419", Spanish, LatinAmerica)
TEST_CTOR("fr_MA", French, Morocco)
// test default countries for languages