diff --git a/src/class-elements/prod-private-async-method.case b/src/class-elements/prod-private-async-method.case index 872c31c74b2ff34f07c861d550aa9d74c95b4de3..d2d70fb17dc52678df57e97b580efa1b2f60966c 100644 --- a/src/class-elements/prod-private-async-method.case +++ b/src/class-elements/prod-private-async-method.case @@ -17,7 +17,7 @@ async #m() { return 42; } //- constructor assert.sameValue(this.#m.name, '#m', 'function name inside constructor'); ctorPromise = this.#m().then(value => { - assert.sameValue(this.#m(), 42, 'already defined in the ctor'); + assert.sameValue(value, 42, 'already defined in the ctor'); }, $DONE); //- assertions diff --git a/test/built-ins/Array/prototype/flatMap/non-callable-argument-throws.js b/test/built-ins/Array/prototype/flatMap/non-callable-argument-throws.js index aee6e4b6c016834e1ece528e7804a73458f7f27c..c9b71441358a30b573e36b061b21f129057a3c81 100644 --- a/test/built-ins/Array/prototype/flatMap/non-callable-argument-throws.js +++ b/test/built-ins/Array/prototype/flatMap/non-callable-argument-throws.js @@ -7,7 +7,7 @@ description: > features: [Array.prototype.flatMap] ---*/ -assert(Array.prototype.flatMap); +assert.sameValue(typeof Array.prototype.flatMap, "function"); assert.throws(TypeError, function() { [].flatMap({}); diff --git a/test/built-ins/Reflect/ownKeys/return-on-corresponding-order-large-index.js b/test/built-ins/Reflect/ownKeys/return-on-corresponding-order-large-index.js index 899737ea86f109aa85c8478beed02f6cc1c949cc..95f59136a6541c0927a60640b822f195e7027712 100644 --- a/test/built-ins/Reflect/ownKeys/return-on-corresponding-order-large-index.js +++ b/test/built-ins/Reflect/ownKeys/return-on-corresponding-order-large-index.js @@ -15,10 +15,10 @@ info: | 9.1.12 [[OwnPropertyKeys]] ( ) 1. Let keys be a new empty List. - 2. For each own property key P of O that is an integer index, in ascending + 2. For each own property key P of O that is an array index, in ascending numeric index order a. Add P as the last element of keys. - 3. For each own property key P of O that is a String but is not an integer + 3. For each own property key P of O that is a String but is not an array index, in property creation order a. Add P as the last element of keys. 4. For each own property key P of O that is a Symbol, in property creation @@ -36,18 +36,22 @@ var o1 = { [Number.MAX_SAFE_INTEGER]: true, [Symbol.for('z')]: true, 12345678901: true, + 4294967294: true, + 4294967295: true, }; var result = Reflect.ownKeys(o1); -assert.sameValue(result.length, 7); +assert.sameValue(result.length, 9); assert.sameValue(result[0], '1'); -assert.sameValue(result[1], '12345678900'); -assert.sameValue(result[2], '12345678901'); -assert.sameValue(result[3], String(Number.MAX_SAFE_INTEGER)); -assert.sameValue(result[4], 'b'); -assert.sameValue(result[5], 'a'); -assert.sameValue(result[6], Symbol.for('z')); +assert.sameValue(result[1], '4294967294'); +assert.sameValue(result[2], '12345678900'); +assert.sameValue(result[3], 'b'); +assert.sameValue(result[4], 'a'); +assert.sameValue(result[5], String(Number.MAX_SAFE_INTEGER)); +assert.sameValue(result[6], '12345678901'); +assert.sameValue(result[7], '4294967295'); +assert.sameValue(result[8], Symbol.for('z')); var o2 = {}; @@ -58,15 +62,19 @@ o2.a = true; o2[Number.MAX_SAFE_INTEGER] = true; o2[Symbol.for('z')] = true; o2[12345678901] = true; +o2[4294967294] = true; +o2[4294967295] = true; result = Reflect.ownKeys(o2); -assert.sameValue(result.length, 7); +assert.sameValue(result.length, 9); assert.sameValue(result[0], '1'); -assert.sameValue(result[1], '12345678900'); -assert.sameValue(result[2], '12345678901'); -assert.sameValue(result[3], String(Number.MAX_SAFE_INTEGER)); -assert.sameValue(result[4], 'b'); -assert.sameValue(result[5], 'a'); -assert.sameValue(result[6], Symbol.for('z')); +assert.sameValue(result[1], '4294967294'); +assert.sameValue(result[2], '12345678900'); +assert.sameValue(result[3], 'b'); +assert.sameValue(result[4], 'a'); +assert.sameValue(result[5], String(Number.MAX_SAFE_INTEGER)); +assert.sameValue(result[6], '12345678901'); +assert.sameValue(result[7], '4294967295'); +assert.sameValue(result[8], Symbol.for('z')); diff --git a/test/intl402/NumberFormat/currencyDisplay-unit.js b/test/intl402/NumberFormat/currencyDisplay-unit.js index c4660f233516b93dce840c6cba1e3b7a33a47b8c..30d46ba58a582dccd9baf3878a3d7dfc4d148f1b 100644 --- a/test/intl402/NumberFormat/currencyDisplay-unit.js +++ b/test/intl402/NumberFormat/currencyDisplay-unit.js @@ -7,7 +7,7 @@ description: Checks handling of valid values for the numeric option to the Relat info: | SetNumberFormatUnitOptions ( intlObj, options ) - 6. Let currencyDisplay be ? GetOption(options, "currencyDisplay", "string", « "code", "symbol", "narrowSymbol", "name" », "symbol"). + 6. Let currencyDisplay be ? GetOption(options, "currencyDisplay", "string", « "code", "symbol", "narrow-symbol", "name" », "symbol"). 11. If style is "currency", then f. Set intlObj.[[CurrencyDisplay]] to currencyDisplay. @@ -16,8 +16,8 @@ features: [Intl.NumberFormat-unified] const validOptions = [ [undefined, "symbol"], - ["narrowSymbol", "narrowSymbol"], - [{ toString() { return "narrowSymbol"; } }, "narrowSymbol"], + ["narrow-symbol", "narrow-symbol"], + [{ toString() { return "narrow-symbol"; } }, "narrow-symbol"], ]; for (const [validOption, expected] of validOptions) { diff --git a/test/intl402/NumberFormat/style-unit.js b/test/intl402/NumberFormat/style-unit.js index da51ac0cb3154f03b18fb7d72e743fc92e1382ae..d50d55b1bdb67742764af9ed5319e3c042c3ffca 100644 --- a/test/intl402/NumberFormat/style-unit.js +++ b/test/intl402/NumberFormat/style-unit.js @@ -20,7 +20,7 @@ const validOptions = [ ]; for (const [validOption, expected] of validOptions) { - const nf = new Intl.NumberFormat([], {"style": validOption}); + const nf = new Intl.NumberFormat([], {"style": validOption, "unit": "generic"}); const resolvedOptions = nf.resolvedOptions(); assert.sameValue(resolvedOptions.style, expected); } diff --git a/test/intl402/Segmenter/iterator/following.js b/test/intl402/Segmenter/iterator/following.js index 7ae63165070b97137206d630ce5573f0a31f6b45..286541c4ebd810f33868eaa887febd5e821435be 100644 --- a/test/intl402/Segmenter/iterator/following.js +++ b/test/intl402/Segmenter/iterator/following.js @@ -25,7 +25,7 @@ const tests = [ ]; for (const [input, position] of tests) { - assert.sameValue(iter.following(0 | input), false); + assert.sameValue(iter.following(input), false); assert.sameValue(iter.position, position, String(input)); } diff --git a/test/intl402/Segmenter/iterator/granularity.js b/test/intl402/Segmenter/iterator/granularity.js index d889f91a7d477175ca25030115d984325f057677..573593d951cd734ba18974981f346bdd9b1c9fd5 100644 --- a/test/intl402/Segmenter/iterator/granularity.js +++ b/test/intl402/Segmenter/iterator/granularity.js @@ -14,9 +14,5 @@ for (const granularity of ["grapheme", "word", "sentence", "line"]) { assert.sameValue(typeof iter.position, "number"); assert.sameValue(iter.position, 0); - if (granularity === "grapheme") { - assert.sameValue(iter.breakType, undefined); - } else { - assert.sameValue(typeof iter.breakType, "string"); - } + assert.sameValue(iter.breakType, undefined); } diff --git a/test/intl402/Segmenter/iterator/preceding.js b/test/intl402/Segmenter/iterator/preceding.js index 55eae7f96c8548effaa78fb2b0012281dccba84e..56a91a34e348ef403c25d21772e4ea8746996124 100644 --- a/test/intl402/Segmenter/iterator/preceding.js +++ b/test/intl402/Segmenter/iterator/preceding.js @@ -23,13 +23,12 @@ const tests = [ ]; for (const [input, position] of tests) { - assert.sameValue(iter.preceding(0 | input), false); + assert.sameValue(iter.preceding(input), false); assert.sameValue(iter.position, position, String(input)); } assert.throws(RangeError, () => iter.preceding("ABC")); assert.throws(RangeError, () => iter.preceding(null)); -assert.throws(RangeError, () => iter.preceding(1.4)); assert.throws(RangeError, () => iter.preceding(-3)); // 1.5.3.3 %SegmentIteratorPrototype%.preceding( [ from ] ) diff --git a/test/intl402/Segmenter/prototype/segment/segment-line.js b/test/intl402/Segmenter/prototype/segment/segment-line.js index 7ad7262eb3461c211315dde4cf155a5a9f9b2b58..502d1b29131227f5e18e97c9f19ffaf9f0cf8352 100644 --- a/test/intl402/Segmenter/prototype/segment/segment-line.js +++ b/test/intl402/Segmenter/prototype/segment/segment-line.js @@ -29,6 +29,6 @@ for (const text of [ "ë²•ì› â€œë‹¤ìŠ¤ 지분 처분권·수ìµê¶Œ ëª¨ë‘ MBê°€ ë³´ìœ â€", // Korean ]) { const iter = seg.segment(text); - assert(["soft", "hard"].includes(iter.breakType), iter.breakType); + assert.sameValue(undefined, iter.breakType); assert.sameValue(0, iter.position); } diff --git a/test/intl402/Segmenter/prototype/segment/segment-sentence.js b/test/intl402/Segmenter/prototype/segment/segment-sentence.js index 3ba03f574606bb6a05b19fcbda9b7d1862c3c197..3bd1d41694df38f61d0d499b8b017a281ae74ef2 100644 --- a/test/intl402/Segmenter/prototype/segment/segment-sentence.js +++ b/test/intl402/Segmenter/prototype/segment/segment-sentence.js @@ -29,6 +29,6 @@ for (const text of [ "ë²•ì› â€œë‹¤ìŠ¤ 지분 처분권·수ìµê¶Œ ëª¨ë‘ MBê°€ ë³´ìœ â€", // Korean ]) { const iter = seg.segment(text); - assert(["sep", "term"].includes(iter.breakType), iter.breakType); + assert.sameValue(undefined, iter.breakType); assert.sameValue(0, iter.position); } diff --git a/test/intl402/Segmenter/prototype/segment/segment-word.js b/test/intl402/Segmenter/prototype/segment/segment-word.js index 935eadb38e852061f4dac276d7301199570d4a8a..9eb8e8461ceb5f097fae53afd8120f3b2dc4a889 100644 --- a/test/intl402/Segmenter/prototype/segment/segment-word.js +++ b/test/intl402/Segmenter/prototype/segment/segment-word.js @@ -29,6 +29,6 @@ for (const text of [ "ë²•ì› â€œë‹¤ìŠ¤ 지분 처분권·수ìµê¶Œ ëª¨ë‘ MBê°€ ë³´ìœ â€", // Korean ]) { const iter = seg.segment(text); - assert(["word", "none"].includes(iter.breakType), iter.breakType); + assert.sameValue(undefined, iter.breakType); assert.sameValue(0, iter.position); } diff --git a/test/language/expressions/class/private-methods/prod-private-async-method.js b/test/language/expressions/class/private-methods/prod-private-async-method.js index f2247d13fbf8217e7a2c02367fef192221afc8b2..7d16e69b1fcc955e1cd924d64316ea9bf3409b8a 100644 --- a/test/language/expressions/class/private-methods/prod-private-async-method.js +++ b/test/language/expressions/class/private-methods/prod-private-async-method.js @@ -99,7 +99,7 @@ var C = class { assert.sameValue(this.#m.name, '#m', 'function name inside constructor'); ctorPromise = this.#m().then(value => { - assert.sameValue(this.#m(), 42, 'already defined in the ctor'); + assert.sameValue(value, 42, 'already defined in the ctor'); }, $DONE); } diff --git a/test/language/statements/class/private-methods/prod-private-async-method.js b/test/language/statements/class/private-methods/prod-private-async-method.js index ed14a42147b564ced24620d5e08042f0e3f15176..bcfc9102606fe0648b1c377cc4a9c42d71e3b146 100644 --- a/test/language/statements/class/private-methods/prod-private-async-method.js +++ b/test/language/statements/class/private-methods/prod-private-async-method.js @@ -98,7 +98,7 @@ class C { assert.sameValue(this.#m.name, '#m', 'function name inside constructor'); ctorPromise = this.#m().then(value => { - assert.sameValue(this.#m(), 42, 'already defined in the ctor'); + assert.sameValue(value, 42, 'already defined in the ctor'); }, $DONE); }