mirror of
https://github.com/tc39/test262.git
synced 2025-07-25 23:14:47 +02:00
Add unscopable tests
This commit is contained in:
parent
a4aeea09ae
commit
6c5e421806
@ -13,13 +13,15 @@ info: |
|
|||||||
4. Perform CreateDataProperty(unscopableList, "fill", true).
|
4. Perform CreateDataProperty(unscopableList, "fill", true).
|
||||||
5. Perform CreateDataProperty(unscopableList, "find", true).
|
5. Perform CreateDataProperty(unscopableList, "find", true).
|
||||||
6. Perform CreateDataProperty(unscopableList, "findIndex", true).
|
6. Perform CreateDataProperty(unscopableList, "findIndex", true).
|
||||||
7. Perform CreateDataProperty(unscopableList, "flat", true).
|
7. Perform CreateDataProperty(unscopableList, "findLast", true).
|
||||||
8. Perform CreateDataProperty(unscopableList, "flatMap", true).
|
8. Perform CreateDataProperty(unscopableList, "findLastIndex", true).
|
||||||
9. Perform CreateDataProperty(unscopableList, "includes", true).
|
9. Perform CreateDataProperty(unscopableList, "flat", true).
|
||||||
10. Perform CreateDataProperty(unscopableList, "keys", true).
|
10. Perform CreateDataProperty(unscopableList, "flatMap", true).
|
||||||
11. Perform CreateDataProperty(unscopableList, "values", true).
|
11. Perform CreateDataProperty(unscopableList, "includes", true).
|
||||||
12. Assert: Each of the above calls returns true.
|
12. Perform CreateDataProperty(unscopableList, "keys", true).
|
||||||
13. Return unscopableList.
|
13. Perform CreateDataProperty(unscopableList, "values", true).
|
||||||
|
14. Assert: Each of the above calls returns true.
|
||||||
|
15. Return unscopableList.
|
||||||
includes: [propertyHelper.js]
|
includes: [propertyHelper.js]
|
||||||
features: [Symbol.unscopables]
|
features: [Symbol.unscopables]
|
||||||
---*/
|
---*/
|
||||||
@ -53,6 +55,17 @@ verifyEnumerable(unscopables, 'findIndex');
|
|||||||
verifyWritable(unscopables, 'findIndex');
|
verifyWritable(unscopables, 'findIndex');
|
||||||
verifyConfigurable(unscopables, 'findIndex');
|
verifyConfigurable(unscopables, 'findIndex');
|
||||||
|
|
||||||
|
|
||||||
|
assert.sameValue(unscopables.findLast, true, '`findLast` property value');
|
||||||
|
verifyEnumerable(unscopables, 'findLast');
|
||||||
|
verifyWritable(unscopables, 'findLast');
|
||||||
|
verifyConfigurable(unscopables, 'findLast');
|
||||||
|
|
||||||
|
assert.sameValue(unscopables.findLastIndex, true, '`findLastIndex` property value');
|
||||||
|
verifyEnumerable(unscopables, 'findLastIndex');
|
||||||
|
verifyWritable(unscopables, 'findLastIndex');
|
||||||
|
verifyConfigurable(unscopables, 'findLastIndex');
|
||||||
|
|
||||||
assert.sameValue(unscopables.flat, true, '`flat` property value');
|
assert.sameValue(unscopables.flat, true, '`flat` property value');
|
||||||
verifyEnumerable(unscopables, 'flat');
|
verifyEnumerable(unscopables, 'flat');
|
||||||
verifyWritable(unscopables, 'flat');
|
verifyWritable(unscopables, 'flat');
|
||||||
|
Loading…
x
Reference in New Issue
Block a user