test262/test/intl402
Frank Yung-Fong Tang 9997a26c7d
Fix tests on {localeMatcher: "lookup"} (#3008)
* Fix test for only {localeMatcher: "lookup"}

The expectation that "sr-Thai-RS" would be returned is only true with the 
9.2.2 BestAvailableLocale ( availableLocales, locale )
https://tc39.es/ecma402/#sec-bestavailablelocale
algorithm used by 9.2.3 LookupMatcher ( availableLocales, requestedLocales )
https://tc39.es/ecma402/#sec-lookupmatcher

The default for localeMatcher is "best fit" but not "lookup" for all Intl objects.

And for 9.2.4 BestFitMatcher ( availableLocales, requestedLocales )
https://tc39.es/ecma402/#sec-bestfitmatcher
It may not match "sr-Thai-RS" for "sr"  and return ["de", "zh-CN"] instead. Therefore, we need to change this test to only test on {localeMatcher: "lookup"}

* Add option to getLocaleSupportInfo

Needed to test different localeMatcher

* only test for "lookup" localeMatcher

* Get the info based on the localeMatcher

* pass in localeMatcher to getLocaleSupportInfo
2021-06-24 13:37:33 -04:00
..
Array/prototype/toLocaleString Various test cases for cross-browser compliance bugs 2018-05-03 09:27:27 -07:00
BigInt/prototype/toLocaleString Update test files to follow lint rule 2019-07-15 14:03:25 -04:00
Collator Set function `length` and `name` in `CreateBuiltinFunction` 2021-01-29 09:45:20 -05:00
Date/prototype Frontmatter: fixup "info: >" to "info: |" 2018-01-05 12:27:59 -05:00
DateTimeFormat Add DateTimeFormat tests for OrdinaryHasInstance 2021-02-16 12:20:50 -05:00
DisplayNames Change Intl.(ListFormat|DisplayNames|Segmenter) (#2952) 2021-03-08 19:31:26 -08:00
Intl Map "cel-gaulish" to "xtg" 2020-12-16 11:59:06 -05:00
ListFormat Change Intl.(ListFormat|DisplayNames|Segmenter) (#2952) 2021-03-08 19:31:26 -08:00
Locale intl402: add output tests for locale-info (#3007) 2021-06-24 13:20:47 -04:00
Number/prototype/toLocaleString Intl: PluralRules, NumberFormat, Number & getCanonicalLocales to use verifyProperty 2018-05-18 12:35:06 -04:00
NumberFormat Add NumberFormat tests for OrdinaryHasInstance 2021-02-16 12:20:50 -05:00
PluralRules Intl: Add coverage for meaningful @@toStringTag values (#2634) 2020-06-01 15:40:35 -07:00
RelativeTimeFormat correct style-short.js 2020-04-25 18:48:40 -04:00
Segmenter Fix tests on {localeMatcher: "lookup"} (#3008) 2021-06-24 13:37:33 -04:00
String/prototype Frontmatter: fixup "info: >" to "info: |" 2018-01-05 12:27:59 -05:00
TypedArray/prototype/toLocaleString Various test cases for cross-browser compliance bugs 2018-05-03 09:27:27 -07:00
constructors-string-and-single-element-array.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
constructors-taint-Object-prototype-2.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
constructors-taint-Object-prototype.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
default-locale-is-canonicalized.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
default-locale-is-supported.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
fallback-locales-are-supported.js Fix tests on {localeMatcher: "lookup"} (#3008) 2021-06-24 13:37:33 -04:00
language-tags-canonicalized.js Update tests to parse language tags as Unicode BCP 47 Locale Identifiers 2019-07-21 05:44:21 -07:00
language-tags-invalid.js Update tests to parse language tags as Unicode BCP 47 Locale Identifiers 2019-07-21 05:44:21 -07:00
language-tags-valid.js Update tests to parse language tags as Unicode BCP 47 Locale Identifiers 2019-07-21 05:44:21 -07:00
language-tags-with-underscore.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-consistent-with-resolvedOptions.js Fix tests on {localeMatcher: "lookup"} (#3008) 2021-06-24 13:37:33 -04:00
supportedLocalesOf-default-locale-and-zxx-locale.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-duplicate-elements-removed.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-empty-and-undefined.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-locales-arg-coered-to-object.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-locales-arg-empty-array.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-returned-array-elements-are-not-frozen.js Change tests according to ecma402/pull/278 (#2031) 2019-01-18 14:15:37 -02:00
supportedLocalesOf-taint-Array-2.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-taint-Array.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-test-option-localeMatcher.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-throws-if-element-not-string-or-object.js Use more descriptive names for Intl test files 2017-12-21 16:46:56 -05:00
supportedLocalesOf-unicode-extensions-ignored.js Fix tests on {localeMatcher: "lookup"} (#3008) 2021-06-24 13:37:33 -04:00