From 777bae581a08c7b7ccd3278f8ce27f5757aa2785 Mon Sep 17 00:00:00 2001 From: "jochen@chromium.org" Date: Thu, 1 Aug 2013 19:43:06 +0000 Subject: [PATCH] Reenable tests that need to access the default timezone. It's now available via builtins. BUG=v8:2475 R=mstarzinger@chromium.org Review URL: https://codereview.chromium.org/21512002 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16016 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- test/intl/break-iterator/default-locale.js | 2 +- .../break-iterator/wellformed-unsupported-locale.js | 2 +- test/intl/collator/default-locale.js | 4 ++-- test/intl/collator/wellformed-unsupported-locale.js | 2 +- test/intl/date-format/default-locale.js | 2 +- .../intl/date-format/wellformed-unsupported-locale.js | 2 +- test/intl/intl.status | 11 ++--------- test/intl/number-format/default-locale.js | 2 +- .../number-format/wellformed-unsupported-locale.js | 2 +- test/intl/testcfg.py | 2 +- 10 files changed, 12 insertions(+), 19 deletions(-) diff --git a/test/intl/break-iterator/default-locale.js b/test/intl/break-iterator/default-locale.js index 39a88574f..d8d5aeadb 100644 --- a/test/intl/break-iterator/default-locale.js +++ b/test/intl/break-iterator/default-locale.js @@ -38,7 +38,7 @@ assertFalse(options.locale === ''); assertFalse(options.locale === undefined); // Then check for equality. -assertEquals(options.locale, getDefaultLocale()); +assertEquals(options.locale, %GetDefaultICULocale()); var iteratorNone = new Intl.v8BreakIterator(); assertEquals(options.locale, iteratorNone.resolvedOptions().locale); diff --git a/test/intl/break-iterator/wellformed-unsupported-locale.js b/test/intl/break-iterator/wellformed-unsupported-locale.js index 56457b482..5ac8fbcd4 100644 --- a/test/intl/break-iterator/wellformed-unsupported-locale.js +++ b/test/intl/break-iterator/wellformed-unsupported-locale.js @@ -29,4 +29,4 @@ var iterator = Intl.v8BreakIterator(['xx']); -assertEquals(iterator.resolvedOptions().locale, getDefaultLocale()); +assertEquals(iterator.resolvedOptions().locale, %GetDefaultICULocale()); diff --git a/test/intl/collator/default-locale.js b/test/intl/collator/default-locale.js index f6ffba8e1..db9b1e733 100644 --- a/test/intl/collator/default-locale.js +++ b/test/intl/collator/default-locale.js @@ -38,7 +38,7 @@ assertFalse(options.locale === ''); assertFalse(options.locale === undefined); // Then check for equality. -assertEquals(options.locale, getDefaultLocale()); +assertEquals(options.locale, %GetDefaultICULocale()); var collatorNone = new Intl.Collator(); assertEquals(options.locale, collatorNone.resolvedOptions().locale); @@ -48,5 +48,5 @@ var collatorBraket = new Intl.Collator({}); assertEquals(options.locale, collatorBraket.resolvedOptions().locale); var collatorWithOptions = new Intl.Collator(undefined, {usage: 'search'}); -assertEquals(getDefaultLocale() + '-u-co-search', +assertEquals(%GetDefaultICULocale() + '-u-co-search', collatorWithOptions.resolvedOptions().locale); diff --git a/test/intl/collator/wellformed-unsupported-locale.js b/test/intl/collator/wellformed-unsupported-locale.js index ea143fdc6..3963d47a6 100644 --- a/test/intl/collator/wellformed-unsupported-locale.js +++ b/test/intl/collator/wellformed-unsupported-locale.js @@ -29,4 +29,4 @@ var collator = Intl.Collator(['xx']); -assertEquals(collator.resolvedOptions().locale, getDefaultLocale()); +assertEquals(collator.resolvedOptions().locale, %GetDefaultICULocale()); diff --git a/test/intl/date-format/default-locale.js b/test/intl/date-format/default-locale.js index 2dcb0f8ae..8e9b7fcec 100644 --- a/test/intl/date-format/default-locale.js +++ b/test/intl/date-format/default-locale.js @@ -38,7 +38,7 @@ assertFalse(options.locale === ''); assertFalse(options.locale === undefined); // Then check for equality. -assertEquals(options.locale, getDefaultLocale()); +assertEquals(options.locale, %GetDefaultICULocale()); var dtfNone = new Intl.DateTimeFormat(); assertEquals(options.locale, dtfNone.resolvedOptions().locale); diff --git a/test/intl/date-format/wellformed-unsupported-locale.js b/test/intl/date-format/wellformed-unsupported-locale.js index 8867ec644..6f063abbd 100644 --- a/test/intl/date-format/wellformed-unsupported-locale.js +++ b/test/intl/date-format/wellformed-unsupported-locale.js @@ -29,4 +29,4 @@ var dtf = Intl.DateTimeFormat(['xx']); -assertEquals(dtf.resolvedOptions().locale, getDefaultLocale()); +assertEquals(dtf.resolvedOptions().locale, %GetDefaultICULocale()); diff --git a/test/intl/intl.status b/test/intl/intl.status index b0de06a4b..7ef0abb4d 100644 --- a/test/intl/intl.status +++ b/test/intl/intl.status @@ -27,14 +27,7 @@ prefix intl -# The following tests use getDefaultLocale() or getDefaultTimezone(). -break-iterator/default-locale: FAIL -break-iterator/wellformed-unsupported-locale: FAIL -collator/default-locale: FAIL -collator/wellformed-unsupported-locale: FAIL -date-format/default-locale: FAIL +# The following tests use getDefaultTimeZone(). date-format/resolved-options: FAIL date-format/timezone: FAIL -date-format/wellformed-unsupported-locale: FAIL -number-format/default-locale: FAIL -number-format/wellformed-unsupported-locale: FAIL +general/v8Intl-exists: FAIL diff --git a/test/intl/number-format/default-locale.js b/test/intl/number-format/default-locale.js index 0d5e24dd7..cd67ba724 100644 --- a/test/intl/number-format/default-locale.js +++ b/test/intl/number-format/default-locale.js @@ -38,7 +38,7 @@ assertFalse(options.locale === ''); assertFalse(options.locale === undefined); // Then check for equality. -assertEquals(options.locale, getDefaultLocale()); +assertEquals(options.locale, %GetDefaultICULocale()); var nfNone = new Intl.NumberFormat(); assertEquals(options.locale, nfNone.resolvedOptions().locale); diff --git a/test/intl/number-format/wellformed-unsupported-locale.js b/test/intl/number-format/wellformed-unsupported-locale.js index e3fe9cc08..195eba4c1 100644 --- a/test/intl/number-format/wellformed-unsupported-locale.js +++ b/test/intl/number-format/wellformed-unsupported-locale.js @@ -29,4 +29,4 @@ var nf = Intl.NumberFormat(['xx']); -assertEquals(nf.resolvedOptions().locale, getDefaultLocale()); +assertEquals(nf.resolvedOptions().locale, %GetDefaultICULocale()); diff --git a/test/intl/testcfg.py b/test/intl/testcfg.py index d25683bed..09d29d0be 100644 --- a/test/intl/testcfg.py +++ b/test/intl/testcfg.py @@ -52,7 +52,7 @@ class IntlTestSuite(testsuite.TestSuite): return tests def GetFlagsForTestCase(self, testcase, context): - flags = [] + context.mode_flags + flags = ["--allow-natives-syntax"] + context.mode_flags files = [] files.append(os.path.join(self.root, "assert.js")) -- 2.34.1