Commit Graph

32 Commits

Author SHA1 Message Date
Daniel Ehrenberg a9d9ab1a51
Add tests for some NumberFormat options edge cases
Closes #888

These tests are regression tests for V8 failures at top of tree,
https://bugs.chromium.org/p/v8/issues/detail?id=6015
https://bugs.chromium.org/p/v8/issues/detail?id=6016

Neither issue is present in JSC or SpiderMonkey. They are fixed
by the V8 patch
https://codereview.chromium.org/2717613005
2017-03-23 11:50:33 -07:00
Leo Balter 6c20a250f2 Add references to fixed tests for NumberFormat operations (#874)
Ref #856
Ref #857
Ref tc39/ecma402#128
2017-03-13 10:47:30 -07:00
vabr-g 42ebb3a9ab Add test for NumberFormat default minimumSignificantDigits (#864) 2017-03-01 16:39:57 -05:00
André Bargull 6b09ad0459 Update YAML frontmatter of some tests to be compatible with monkeyYaml (#862) 2017-03-01 16:35:37 -05:00
Viktor 58b326f0c4 fix for the wrong test of Intl.NumberFormat (ToRawPrecision) (#857)
1) (123.44500) == 123.444999999999993179
2) (123.44500).toPrecision(5) === "123.44" gives correct value in Chrome and Firefox;

Ref https://github.com/tc39/ecma402/issues/128
2017-03-01 16:14:33 -05:00
Viktor 9fd3b582c7 fix for the wrong test of Intl.NumberFormat (ToRawFixed) (#856)
Note:
12344501000000000487815444678311936 === 12344501000000000000000000000000000 for binary64 floating points;

Ref https://github.com/tc39/ecma402/issues/128
2017-03-01 16:14:00 -05:00
André Bargull 76320ad18d Update tests when Intl constructor is called as a function
https://github.com/tc39/ecma402/issues/57
https://github.com/tc39/ecma402/pull/84
2017-02-22 18:05:34 +01:00
André Bargull fdccf26317 Update length property test for Intl.DateTimeFormat.prototype.format
Per https://github.com/tc39/ecma402/issues/76
2017-02-22 18:05:16 +01:00
littledan e31b7c43b0 Test for case-insensitivity in invalid BCP 47 usage (#836)
This patch adds a regression test for a previous V8 bug reported originally at
https://bugs.chromium.org/p/v8/issues/detail?id=4215
2017-01-20 11:56:46 -08:00
Zibi Braniecki 82c2ca0709 Add Intl.PluralRules tests (#782)
* Add Intl.PluralRules tests

* document the tests
2017-01-18 15:56:44 -08:00
Zibi Braniecki 28fc809f3e Remove BYR currency code which has been removed from ISO 4217 (#818) 2017-01-09 14:27:23 -08:00
jungshik 6a0f1189eb Drop 3 tests testing an obsolete Ecma402 v1 spec (#807)
The following three tests check an obsolete provision in Ecma 402
v1 regarding Intl.{Collator,DateTimeFormat,NumberFormat} constructor
called as a function.

Collator/10.1.2.1_4.js
DateTimeFormat/12.1.2.1_4.js
NumberFormat/11.1.2.1_4.js
2016-12-21 11:11:39 -08:00
jungshik db3aa4ca4f Replace islamicc with islamic-umalqura in getCanonicalLocales/main.js (Intl402) (#789)
* Replace islamicc with islamic-umalqura

Per discussion in #743, it's implementation-dependent how ismalicc is
canonicalized. However, 'islamic-umalqura' should be treated the same
way by all implementations.

* Remove ar-ma-u-ca-islamic-umalqura per discussion
2016-12-19 11:34:35 -08:00
Leo Balter febb11b249 Revert "islamicc should be canonicalized to islamic-civil (#747)" (#774)
This reverts commit da4f4385fd.
2016-10-14 11:05:41 -07:00
jungshik da4f4385fd islamicc should be canonicalized to islamic-civil (#747)
Moves ismalicc test out of main.js and creates a new
test, preferred-subtag.js (per RFC 5646 section 4.5 and
http://www.unicode.org/repos/cldr/tags/latest/common/bcp47/calendar.xml
)

Fix #743
2016-09-12 12:54:55 -07:00
jungshik fb45ed9772 Test that getCanonicalLocales() returns a mutable object. (#746)
Will fix #745

Besides, add additional checks to make sure that getCanonicalLocales()
returns an array.
2016-08-22 14:25:00 -07:00
Zibi Braniecki cac55f2999 NumberFormat.prototype.formatToParts tests, part 1 (#744) 2016-08-15 15:23:34 -07:00
Zibi Braniecki 1bf44eb349 Add DateTimeFormat.prototype.formatToParts tests (#734) 2016-07-28 10:22:09 -07:00
Zibi Braniecki aeb88953f0 Add tests for Intl.getCanonicalLocales 2016-06-07 14:52:04 -04:00
Mike Pennisi eb644bb2da Reduce reliance on `fnGlobalObject.js`
This harness function is not necessary in the majority of cases in which
it is used. Remove its usage to simplify tests and decrease the amount
of domain-specific knowledge necessary to contribute to the test suite.

Persist the harness function itself for use by future tests for ES2015
modules (such a helper is necessary for tests that are interpreted as
module code).
2016-04-25 11:09:21 -07:00
Leonardo Balter bf782c8421 s/id/esid
Fixes #477
2016-02-22 09:47:42 -05:00
André Bargull 31a9036e9b Add coverage for 'name' property of Intl built-in functions 2016-02-12 18:58:57 +01:00
André Bargull 3a30a72269 Add tests for special case mappings 2015-09-07 18:22:07 +02:00
André Bargull 932bd1a12c Move intl tests to sub-folders 2015-07-31 17:12:08 +02:00
André Bargull d5075819e9 Check resolved time zone is valid 2015-07-08 19:13:55 +02:00
André Bargull 438b87b5b6 Intl sub-classing is now restricted to class syntax. 2015-07-08 19:13:31 +02:00
André Bargull 888524ff1d Intl constructors are no longer able to initialize arbitrary objects as Intl objects. Update tests accordingly. 2015-07-08 19:13:06 +02:00
André Bargull b5efa1dd83 Update comments to match correct ES2015 chapter 2015-07-08 19:12:39 +02:00
Brian Terlson 6311f00ce9 Remove enochian-enochian (fixes gh-227) 2015-04-21 15:08:19 -07:00
André Bargull 6aa73b5a2b Changes for currency data
- Update minor unit for CLF
- Remove withdrawn currencies (LVL, LTL, USS)
- Update link to new location

Fixes #98
2015-03-23 18:45:35 +01:00
André Bargull 0dbafac5a6 Add 'var' declarations for strict mode
This change adds 'var' declarations for global variables to allow the tests to run in strict mode (see issue #35).
Extra care was taken to ensure the changes do not alter the test behavior, for example when implicit creation of global variables are part of the test.
Note: The change does not fix all strict mode errors due to missing 'var' declarations.
2014-12-10 16:37:05 -08:00
Brian Terlson 2a74f0ec1b Reorganize ./test 2014-12-07 15:33:09 -08:00