Fix invalidLanguageTags array

This commit is contained in:
Frank Yung-Fong Tang 2019-01-28 20:58:27 -08:00 committed by Rick Waldron
parent 7238135940
commit dde5d8e546
1 changed files with 3 additions and 3 deletions

View File

@ -43,15 +43,15 @@ for (const [langtag, canonical] of Object.entries(validLanguageTags)) {
}
// unicode_language_subtag = alpha{2,3} | alpha{5,8};
const invalidLanguageTags = {
const invalidLanguageTags = [
"X-u-foo",
"Flob",
"ZORK",
"Blah-latn",
"QuuX-latn-us",
"SPAM-gb-x-Sausages-BACON-eggs",
};
];
for (const langtag of Object.entries(invalidLanguageTags)) {
for (const langtag of invalidLanguageTags) {
assert.throws(RangeError, () => new Intl.Locale(langtag));
}