chore: convert many tests to use verifyProperty (#4263)

Co-authored-by: André Bargull <andre.bargull@gmail.com>
This commit is contained in:
Meghan Denny 2024-10-14 02:25:05 -07:00 committed by GitHub
parent 83fae7f1f2
commit 60963bf468
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
326 changed files with 1703 additions and 1021 deletions

View File

@ -7,6 +7,8 @@ includes: [propertyHelper.js]
esid: sec-array.from
---*/
verifyWritable(Array, "from");
verifyNotEnumerable(Array, "from");
verifyConfigurable(Array, "from");
verifyProperty(Array, "from", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -7,6 +7,8 @@ includes: [propertyHelper.js]
esid: sec-array.isarray
---*/
verifyWritable(Array, "isArray");
verifyNotEnumerable(Array, "isArray");
verifyConfigurable(Array, "isArray");
verifyProperty(Array, "isArray", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -12,6 +12,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Array, 'of');
verifyWritable(Array, 'of');
verifyConfigurable(Array, 'of');
verifyProperty(Array, "of", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -15,6 +15,9 @@ esid: sec-array.prototype-@@iterator
---*/
assert.sameValue(Array.prototype[Symbol.iterator], Array.prototype.values);
verifyNotEnumerable(Array.prototype, Symbol.iterator);
verifyWritable(Array.prototype, Symbol.iterator);
verifyConfigurable(Array.prototype, Symbol.iterator);
verifyProperty(Array.prototype, Symbol.iterator, {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -21,11 +21,16 @@ var unscopables = Array.prototype[Symbol.unscopables];
assert.sameValue(Object.getPrototypeOf(unscopables), null);
assert.sameValue(unscopables.findLast, true, '`findLast` property value');
verifyEnumerable(unscopables, 'findLast');
verifyWritable(unscopables, 'findLast');
verifyConfigurable(unscopables, 'findLast');
verifyProperty(unscopables, "findLast", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.findLastIndex, true, '`findLastIndex` property value');
verifyEnumerable(unscopables, 'findLastIndex');
verifyWritable(unscopables, 'findLastIndex');
verifyConfigurable(unscopables, 'findLastIndex');
verifyProperty(unscopables, "findLastIndex", {
writable: true,
enumerable: true,
configurable: true
});

View File

@ -11,6 +11,8 @@ includes: [propertyHelper.js]
features: [Symbol.unscopables]
---*/
verifyNotEnumerable(Array.prototype, Symbol.unscopables);
verifyNotWritable(Array.prototype, Symbol.unscopables);
verifyConfigurable(Array.prototype, Symbol.unscopables);
verifyProperty(Array.prototype, Symbol.unscopables, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -30,51 +30,71 @@ var unscopables = Array.prototype[Symbol.unscopables];
assert.sameValue(Object.getPrototypeOf(unscopables), null);
assert.sameValue(unscopables.copyWithin, true, '`copyWithin` property value');
verifyEnumerable(unscopables, 'copyWithin');
verifyWritable(unscopables, 'copyWithin');
verifyConfigurable(unscopables, 'copyWithin');
verifyProperty(unscopables, "copyWithin", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.entries, true, '`entries` property value');
verifyEnumerable(unscopables, 'entries');
verifyWritable(unscopables, 'entries');
verifyConfigurable(unscopables, 'entries');
verifyProperty(unscopables, "entries", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.fill, true, '`fill` property value');
verifyEnumerable(unscopables, 'fill');
verifyWritable(unscopables, 'fill');
verifyConfigurable(unscopables, 'fill');
verifyProperty(unscopables, "fill", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.find, true, '`find` property value');
verifyEnumerable(unscopables, 'find');
verifyWritable(unscopables, 'find');
verifyConfigurable(unscopables, 'find');
verifyProperty(unscopables, "find", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.findIndex, true, '`findIndex` property value');
verifyEnumerable(unscopables, 'findIndex');
verifyWritable(unscopables, 'findIndex');
verifyConfigurable(unscopables, 'findIndex');
verifyProperty(unscopables, "findIndex", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.flat, true, '`flat` property value');
verifyEnumerable(unscopables, 'flat');
verifyWritable(unscopables, 'flat');
verifyConfigurable(unscopables, 'flat');
verifyProperty(unscopables, "flat", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.flatMap, true, '`flatMap` property value');
verifyEnumerable(unscopables, 'flatMap');
verifyWritable(unscopables, 'flatMap');
verifyConfigurable(unscopables, 'flatMap');
verifyProperty(unscopables, "flatMap", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.includes, true, '`includes` property value');
verifyEnumerable(unscopables, 'includes');
verifyWritable(unscopables, 'includes');
verifyConfigurable(unscopables, 'includes');
verifyProperty(unscopables, "includes", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.keys, true, '`keys` property value');
verifyEnumerable(unscopables, 'keys');
verifyWritable(unscopables, 'keys');
verifyConfigurable(unscopables, 'keys');
verifyProperty(unscopables, "keys", {
writable: true,
enumerable: true,
configurable: true
});
assert.sameValue(unscopables.values, true, '`values` property value');
verifyEnumerable(unscopables, 'values');
verifyWritable(unscopables, 'values');
verifyConfigurable(unscopables, 'values');
verifyProperty(unscopables, "values", {
writable: true,
enumerable: true,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.concat, 'function', 'The value of `typeof Array.prototype.concat` is expected to be "function"');
verifyNotEnumerable(Array.prototype, "concat");
verifyWritable(Array.prototype, "concat");
verifyConfigurable(Array.prototype, "concat");
verifyProperty(Array.prototype, "concat", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -20,6 +20,8 @@ includes: [propertyHelper.js]
assert.sameValue(Array.prototype.constructor, Array);
verifyNotEnumerable(Array.prototype, 'constructor');
verifyWritable(Array.prototype, 'constructor');
verifyConfigurable(Array.prototype, 'constructor');
verifyProperty(Array.prototype, "constructor", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ assert.sameValue(
'`typeof Array.prototype.copyWithin` is `function`'
);
verifyNotEnumerable(Array.prototype, 'copyWithin');
verifyWritable(Array.prototype, 'copyWithin');
verifyConfigurable(Array.prototype, 'copyWithin');
verifyProperty(Array.prototype, "copyWithin", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -17,6 +17,8 @@ assert.sameValue(
'`typeof Array.prototype.entries` is `function`'
);
verifyNotEnumerable(Array.prototype, 'entries');
verifyWritable(Array.prototype, 'entries');
verifyConfigurable(Array.prototype, 'entries');
verifyProperty(Array.prototype, "entries", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -7,7 +7,7 @@ description: >
"every" property of Array.prototype
info: |
17 ECMAScript Standard Built-in Objects
Every other data property described in clauses 18 through 26 and in Annex B.2
has the attributes { [[Writable]]: true, [[Enumerable]]: false,
[[Configurable]]: true } unless otherwise specified.

View File

@ -14,6 +14,8 @@ assert.sameValue(
'`typeof Array.prototype.fill` is `function`'
);
verifyNotEnumerable(Array.prototype, 'fill');
verifyWritable(Array.prototype, 'fill');
verifyConfigurable(Array.prototype, 'fill');
verifyProperty(Array.prototype, "fill", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.filter, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "filter");
verifyWritable(Array.prototype, "filter");
verifyConfigurable(Array.prototype, "filter");
verifyProperty(Array.prototype, "filter", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -14,6 +14,8 @@ assert.sameValue(
'`typeof Array.prototype.find` is `function`'
);
verifyNotEnumerable(Array.prototype, 'find');
verifyWritable(Array.prototype, 'find');
verifyConfigurable(Array.prototype, 'find');
verifyProperty(Array.prototype, "find", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -14,6 +14,8 @@ assert.sameValue(
'`typeof Array.prototype.findIndex` is `function`'
);
verifyNotEnumerable(Array.prototype, 'findIndex');
verifyWritable(Array.prototype, 'findIndex');
verifyConfigurable(Array.prototype, 'findIndex');
verifyProperty(Array.prototype, "findIndex", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.forEach, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "forEach");
verifyWritable(Array.prototype, "forEach");
verifyConfigurable(Array.prototype, "forEach");
verifyProperty(Array.prototype, "forEach", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -12,6 +12,8 @@ includes: [propertyHelper.js]
features: [Array.prototype.includes]
---*/
verifyNotEnumerable(Array.prototype, "includes");
verifyWritable(Array.prototype, "includes");
verifyConfigurable(Array.prototype, "includes");
verifyProperty(Array.prototype, "includes", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.indexOf, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "indexOf");
verifyWritable(Array.prototype, "indexOf");
verifyConfigurable(Array.prototype, "indexOf");
verifyProperty(Array.prototype, "indexOf", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.join, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "join");
verifyWritable(Array.prototype, "join");
verifyConfigurable(Array.prototype, "join");
verifyProperty(Array.prototype, "join", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -17,6 +17,8 @@ assert.sameValue(
'`typeof Array.prototype.keys` is `function`'
);
verifyNotEnumerable(Array.prototype, 'keys');
verifyWritable(Array.prototype, 'keys');
verifyConfigurable(Array.prototype, 'keys');
verifyProperty(Array.prototype, "keys", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.lastIndexOf, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "lastIndexOf");
verifyWritable(Array.prototype, "lastIndexOf");
verifyConfigurable(Array.prototype, "lastIndexOf");
verifyProperty(Array.prototype, "lastIndexOf", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.map, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "map");
verifyWritable(Array.prototype, "map");
verifyConfigurable(Array.prototype, "map");
verifyProperty(Array.prototype, "map", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.pop, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "pop");
verifyWritable(Array.prototype, "pop");
verifyConfigurable(Array.prototype, "pop");
verifyProperty(Array.prototype, "pop", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -15,6 +15,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Array, 'prototype');
verifyNotWritable(Array, 'prototype');
verifyNotConfigurable(Array, 'prototype');
verifyProperty(Array, 'prototype', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.push, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "push");
verifyWritable(Array.prototype, "push");
verifyConfigurable(Array.prototype, "push");
verifyProperty(Array.prototype, "push", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.reduce, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "reduce");
verifyWritable(Array.prototype, "reduce");
verifyConfigurable(Array.prototype, "reduce");
verifyProperty(Array.prototype, "reduce", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.reduceRight, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "reduceRight");
verifyWritable(Array.prototype, "reduceRight");
verifyConfigurable(Array.prototype, "reduceRight");
verifyProperty(Array.prototype, "reduceRight", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.reverse, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "reverse");
verifyWritable(Array.prototype, "reverse");
verifyConfigurable(Array.prototype, "reverse");
verifyProperty(Array.prototype, "reverse", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.shift, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "shift");
verifyWritable(Array.prototype, "shift");
verifyConfigurable(Array.prototype, "shift");
verifyProperty(Array.prototype, "shift", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.slice, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "slice");
verifyWritable(Array.prototype, "slice");
verifyConfigurable(Array.prototype, "slice");
verifyProperty(Array.prototype, "slice", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.some, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "some");
verifyWritable(Array.prototype, "some");
verifyConfigurable(Array.prototype, "some");
verifyProperty(Array.prototype, "some", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.sort, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "sort");
verifyWritable(Array.prototype, "sort");
verifyConfigurable(Array.prototype, "sort");
verifyProperty(Array.prototype, "sort", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.splice, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "splice");
verifyWritable(Array.prototype, "splice");
verifyConfigurable(Array.prototype, "splice");
verifyProperty(Array.prototype, "splice", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.toLocaleString, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "toLocaleString");
verifyWritable(Array.prototype, "toLocaleString");
verifyConfigurable(Array.prototype, "toLocaleString");
verifyProperty(Array.prototype, "toLocaleString", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.toString, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "toString");
verifyWritable(Array.prototype, "toString");
verifyConfigurable(Array.prototype, "toString");
verifyProperty(Array.prototype, "toString", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.unshift, 'function', 'typeof');
verifyNotEnumerable(Array.prototype, "unshift");
verifyWritable(Array.prototype, "unshift");
verifyConfigurable(Array.prototype, "unshift");
verifyProperty(Array.prototype, "unshift", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -12,6 +12,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Array.prototype.values, 'function');
verifyNotEnumerable(Array.prototype, 'values');
verifyWritable(Array.prototype, 'values');
verifyConfigurable(Array.prototype, 'values');
verifyProperty(Array.prototype, "values", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -12,6 +12,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(ArrayBuffer, "isView");
verifyWritable(ArrayBuffer, "isView");
verifyConfigurable(ArrayBuffer, "isView");
verifyProperty(ArrayBuffer, "isView", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ features: [Symbol.toStringTag]
assert.sameValue(ArrayBuffer.prototype[Symbol.toStringTag], 'ArrayBuffer');
verifyNotEnumerable(ArrayBuffer.prototype, Symbol.toStringTag);
verifyNotWritable(ArrayBuffer.prototype, Symbol.toStringTag);
verifyConfigurable(ArrayBuffer.prototype, Symbol.toStringTag);
verifyProperty(ArrayBuffer.prototype, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -18,6 +18,8 @@ includes: [propertyHelper.js]
assert.sameValue(ArrayBuffer.prototype.constructor, ArrayBuffer);
verifyNotEnumerable(ArrayBuffer.prototype, "constructor");
verifyWritable(ArrayBuffer.prototype, "constructor");
verifyConfigurable(ArrayBuffer.prototype, "constructor");
verifyProperty(ArrayBuffer.prototype, "constructor", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -15,6 +15,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(ArrayBuffer.prototype, "slice");
verifyWritable(ArrayBuffer.prototype, "slice");
verifyConfigurable(ArrayBuffer.prototype, "slice");
verifyProperty(ArrayBuffer.prototype, "slice", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -20,6 +20,8 @@ var ArrayIteratorProto = Object.getPrototypeOf([][Symbol.iterator]());
assert.sameValue("Array Iterator", ArrayIteratorProto[Symbol.toStringTag]);
verifyNotEnumerable(ArrayIteratorProto, Symbol.toStringTag);
verifyNotWritable(ArrayIteratorProto, Symbol.toStringTag);
verifyConfigurable(ArrayIteratorProto, Symbol.toStringTag);
verifyProperty(ArrayIteratorProto, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -12,6 +12,8 @@ features: [Symbol.iterator]
var ArrayIteratorProto = Object.getPrototypeOf([][Symbol.iterator]());
verifyNotEnumerable(ArrayIteratorProto, 'next');
verifyWritable(ArrayIteratorProto, 'next');
verifyConfigurable(ArrayIteratorProto, 'next');
verifyProperty(ArrayIteratorProto, "next", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -23,6 +23,8 @@ assert.sameValue(descriptor.get.name,
'The value of `descriptor.get.name` is `get disposed`'
);
verifyNotEnumerable(descriptor.get, 'name');
verifyNotWritable(descriptor.get, 'name');
verifyConfigurable(descriptor.get, 'name');
verifyProperty(descriptor.get, 'name', {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -17,6 +17,8 @@ assert.sameValue(l0.length, 0);
assert.sameValue(l1.length, 1);
assert.sameValue(l2.length, 2)
verifyNotWritable(l0, 'length');
verifyNotEnumerable(l0, 'length');
verifyConfigurable(l0, 'length');
verifyProperty(l0, 'length', {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -20,6 +20,8 @@ assert.sameValue(
'The value of Atomics[Symbol.toStringTag] is "Atomics"'
);
verifyNotEnumerable(Atomics, Symbol.toStringTag);
verifyNotWritable(Atomics, Symbol.toStringTag);
verifyConfigurable(Atomics, Symbol.toStringTag);
verifyProperty(Atomics, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(this, "Boolean");
verifyWritable(this, "Boolean");
verifyConfigurable(this, "Boolean");
verifyProperty(this, "Boolean", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -8,6 +8,8 @@ description: >
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(this, "DataView");
verifyWritable(this, "DataView");
verifyConfigurable(this, "DataView");
verifyProperty(this, "DataView", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -14,6 +14,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(DataView, "prototype");
verifyNotWritable(DataView, "prototype");
verifyNotConfigurable(DataView, "prototype");
verifyProperty(DataView, "prototype", {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -20,6 +20,8 @@ assert.sameValue(
'The value of DataView.prototype[Symbol.toStringTag] is expected to be "DataView"'
);
verifyNotEnumerable(DataView.prototype, Symbol.toStringTag);
verifyNotWritable(DataView.prototype, Symbol.toStringTag);
verifyConfigurable(DataView.prototype, Symbol.toStringTag);
verifyProperty(DataView.prototype, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(this, "Date");
verifyWritable(this, "Date");
verifyConfigurable(this, "Date");
verifyProperty(this, "Date", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -11,6 +11,8 @@ includes: [propertyHelper.js]
features: [Symbol.toPrimitive]
---*/
verifyNotEnumerable(Date.prototype, Symbol.toPrimitive);
verifyNotWritable(Date.prototype, Symbol.toPrimitive);
verifyConfigurable(Date.prototype, Symbol.toPrimitive);
verifyProperty(Date.prototype, Symbol.toPrimitive, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -23,6 +23,8 @@ assert.sameValue(descriptor.get.name,
'The value of `descriptor.get.name` is `get disposed`'
);
verifyNotEnumerable(descriptor.get, 'name');
verifyNotWritable(descriptor.get, 'name');
verifyConfigurable(descriptor.get, 'name');
verifyProperty(descriptor.get, 'name', {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -18,6 +18,8 @@ assert.sameValue(
'Error.prototype.isPrototypeOf(Error()) returns true'
);
verifyNotEnumerable(Error, 'prototype');
verifyNotWritable(Error, 'prototype');
verifyNotConfigurable(Error, 'prototype');
verifyProperty(Error, 'prototype', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -19,6 +19,8 @@ var message = "my-message";
var error = new Error(message);
verifyEqualTo(error, "message", message);
verifyNotEnumerable(error, "message");
verifyWritable(error, "message");
verifyConfigurable(error, "message");
verifyProperty(error, "message", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(this, "Error");
verifyWritable(this, "Error");
verifyConfigurable(this, "Error");
verifyProperty(this, "Error", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(this, "Function");
verifyWritable(this, "Function");
verifyConfigurable(this, "Function");
verifyProperty(this, "Function", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -12,6 +12,8 @@ includes: [propertyHelper.js]
assert.sameValue(typeof Function.prototype[Symbol.hasInstance], 'function');
verifyNotEnumerable(Function.prototype, Symbol.hasInstance);
verifyNotWritable(Function.prototype, Symbol.hasInstance);
verifyNotConfigurable(Function.prototype, Symbol.hasInstance);
verifyProperty(Function.prototype, Symbol.hasInstance, {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -30,6 +30,8 @@ assert.sameValue(
Object.getPrototypeOf(instance).prototype
);
verifyNotEnumerable(instance, 'prototype');
verifyWritable(instance, 'prototype');
verifyNotConfigurable(instance, 'prototype');
verifyProperty(instance, 'prototype', {
writable: true,
enumerable: false,
configurable: false,
});

View File

@ -21,6 +21,8 @@ assert.sameValue(
GeneratorFunctionPrototype[Symbol.toStringTag], 'GeneratorFunction'
);
verifyNotEnumerable(GeneratorFunctionPrototype, Symbol.toStringTag);
verifyNotWritable(GeneratorFunctionPrototype, Symbol.toStringTag);
verifyConfigurable(GeneratorFunctionPrototype, Symbol.toStringTag);
verifyProperty(GeneratorFunctionPrototype, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -18,6 +18,8 @@ var GeneratorFunction = Object.getPrototypeOf(function*() {}).constructor;
assert.sameValue(GeneratorFunction.prototype.constructor, GeneratorFunction);
verifyNotEnumerable(GeneratorFunction.prototype, 'constructor');
verifyNotWritable(GeneratorFunction.prototype, 'constructor');
verifyConfigurable(GeneratorFunction.prototype, 'constructor');
verifyProperty(GeneratorFunction.prototype, 'constructor', {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -12,6 +12,8 @@ features: [generators]
var GeneratorFunction = Object.getPrototypeOf(function*() {}).constructor;
verifyNotEnumerable(GeneratorFunction, 'prototype');
verifyNotWritable(GeneratorFunction, 'prototype');
verifyNotConfigurable(GeneratorFunction, 'prototype');
verifyProperty(GeneratorFunction, 'prototype', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -18,6 +18,8 @@ assert.sameValue(
Object.getPrototypeOf(function*() {}.prototype)
);
verifyNotEnumerable(GeneratorFunctionPrototype, 'prototype');
verifyNotWritable(GeneratorFunctionPrototype, 'prototype');
verifyConfigurable(GeneratorFunctionPrototype, 'prototype');
verifyProperty(GeneratorFunctionPrototype, 'prototype', {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -21,6 +21,8 @@ var GeneratorPrototype = Object.getPrototypeOf(
assert.sameValue(GeneratorPrototype[Symbol.toStringTag], 'Generator');
verifyNotEnumerable(GeneratorPrototype, Symbol.toStringTag);
verifyNotWritable(GeneratorPrototype, Symbol.toStringTag);
verifyConfigurable(GeneratorPrototype, Symbol.toStringTag);
verifyProperty(GeneratorPrototype, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -16,6 +16,8 @@ var GeneratorPrototype = Generator.prototype;
assert.sameValue(GeneratorPrototype.constructor, Generator);
verifyNotEnumerable(GeneratorPrototype, 'constructor');
verifyNotWritable(GeneratorPrototype, 'constructor');
verifyConfigurable(GeneratorPrototype, 'constructor');
verifyProperty(GeneratorPrototype, 'constructor', {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -13,6 +13,8 @@ features: [generators]
function* g() {}
var GeneratorPrototype = Object.getPrototypeOf(g).prototype;
verifyNotEnumerable(GeneratorPrototype, 'next');
verifyWritable(GeneratorPrototype, 'next');
verifyConfigurable(GeneratorPrototype, 'next');
verifyProperty(GeneratorPrototype, 'next', {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -13,6 +13,8 @@ features: [generators]
function* g() {}
var GeneratorPrototype = Object.getPrototypeOf(g).prototype;
verifyNotEnumerable(GeneratorPrototype, 'return');
verifyWritable(GeneratorPrototype, 'return');
verifyConfigurable(GeneratorPrototype, 'return');
verifyProperty(GeneratorPrototype, 'return', {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -13,6 +13,8 @@ features: [generators]
function* g() {}
var GeneratorPrototype = Object.getPrototypeOf(g).prototype;
verifyNotEnumerable(GeneratorPrototype, 'throw');
verifyWritable(GeneratorPrototype, 'throw');
verifyConfigurable(GeneratorPrototype, 'throw');
verifyProperty(GeneratorPrototype, 'throw', {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -16,6 +16,8 @@ features: [Symbol.toStringTag]
assert.sameValue(JSON[Symbol.toStringTag], 'JSON');
verifyNotEnumerable(JSON, Symbol.toStringTag);
verifyNotWritable(JSON, Symbol.toStringTag);
verifyConfigurable(JSON, Symbol.toStringTag);
verifyProperty(JSON, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -12,6 +12,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(this, 'Map');
verifyWritable(this, 'Map');
verifyConfigurable(this, 'Map');
verifyProperty(this, 'Map', {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -14,6 +14,8 @@ features: [Symbol.iterator]
---*/
assert.sameValue(Map.prototype[Symbol.iterator], Map.prototype.entries);
verifyNotEnumerable(Map.prototype, Symbol.iterator);
verifyWritable(Map.prototype, Symbol.iterator);
verifyConfigurable(Map.prototype, Symbol.iterator);
verifyProperty(Map.prototype, Symbol.iterator, {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -16,6 +16,8 @@ features: [Symbol.toStringTag]
assert.sameValue(Map.prototype[Symbol.toStringTag], 'Map');
verifyNotEnumerable(Map.prototype, Symbol.toStringTag);
verifyNotWritable(Map.prototype, Symbol.toStringTag);
verifyConfigurable(Map.prototype, Symbol.toStringTag);
verifyProperty(Map.prototype, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -16,6 +16,8 @@ assert.sameValue(
'typeof Map.prototype.clear is "function"'
);
verifyNotEnumerable(Map.prototype, 'clear');
verifyWritable(Map.prototype, 'clear');
verifyConfigurable(Map.prototype, 'clear');
verifyProperty(Map.prototype, 'clear', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -11,6 +11,8 @@ includes: [propertyHelper.js]
assert.sameValue(Map.prototype.constructor, Map);
assert.sameValue((new Map()).constructor, Map);
verifyNotEnumerable(Map.prototype, 'constructor');
verifyWritable(Map.prototype, 'constructor');
verifyConfigurable(Map.prototype, 'constructor');
verifyProperty(Map.prototype, 'constructor', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -16,6 +16,8 @@ assert.sameValue(
'typeof Map.prototype.delete is "function"'
);
verifyNotEnumerable(Map.prototype, 'delete');
verifyWritable(Map.prototype, 'delete');
verifyConfigurable(Map.prototype, 'delete');
verifyProperty(Map.prototype, 'delete', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -9,6 +9,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Map, 'prototype');
verifyNotWritable(Map, 'prototype');
verifyNotConfigurable(Map, 'prototype');
verifyProperty(Map, 'prototype', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -17,6 +17,8 @@ assert.sameValue(
'`typeof Map.prototype.entries` is `function`'
);
verifyNotEnumerable(Map.prototype, 'entries');
verifyWritable(Map.prototype, 'entries');
verifyConfigurable(Map.prototype, 'entries');
verifyProperty(Map.prototype, 'entries', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -17,6 +17,8 @@ assert.sameValue(
'`typeof Map.prototype.forEach` is `function`'
);
verifyNotEnumerable(Map.prototype, 'forEach');
verifyWritable(Map.prototype, 'forEach');
verifyConfigurable(Map.prototype, 'forEach');
verifyProperty(Map.prototype, 'forEach', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -17,6 +17,8 @@ assert.sameValue(
'`typeof Map.prototype.get` is `function`'
);
verifyNotEnumerable(Map.prototype, 'get');
verifyWritable(Map.prototype, 'get');
verifyConfigurable(Map.prototype, 'get');
verifyProperty(Map.prototype, 'get', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -17,6 +17,8 @@ assert.sameValue(
'`typeof Map.prototype.has` is `function`'
);
verifyNotEnumerable(Map.prototype, 'has');
verifyWritable(Map.prototype, 'has');
verifyConfigurable(Map.prototype, 'has');
verifyProperty(Map.prototype, 'has', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -17,6 +17,8 @@ assert.sameValue(
'`typeof Map.prototype.keys` is `function`'
);
verifyNotEnumerable(Map.prototype, 'keys');
verifyWritable(Map.prototype, 'keys');
verifyConfigurable(Map.prototype, 'keys');
verifyProperty(Map.prototype, 'keys', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -17,6 +17,8 @@ assert.sameValue(
'`typeof Map.prototype.set` is `function`'
);
verifyNotEnumerable(Map.prototype, 'set');
verifyWritable(Map.prototype, 'set');
verifyConfigurable(Map.prototype, 'set');
verifyProperty(Map.prototype, 'set', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -17,6 +17,8 @@ assert.sameValue(
'`typeof Map.prototype.values` is `function`'
);
verifyNotEnumerable(Map.prototype, 'values');
verifyWritable(Map.prototype, 'values');
verifyConfigurable(Map.prototype, 'values');
verifyProperty(Map.prototype, 'values', {
writable: true,
enumerable: false,
configurable: true,
});

View File

@ -18,6 +18,8 @@ var MapIteratorProto = Object.getPrototypeOf(new Map()[Symbol.iterator]());
assert.sameValue('Map Iterator', MapIteratorProto[Symbol.toStringTag]);
verifyNotEnumerable(MapIteratorProto, Symbol.toStringTag);
verifyNotWritable(MapIteratorProto, Symbol.toStringTag);
verifyConfigurable(MapIteratorProto, Symbol.toStringTag);
verifyProperty(MapIteratorProto, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, 'E');
verifyNotWritable(Math, 'E');
verifyNotConfigurable(Math, 'E');
verifyProperty(Math, 'E', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, 'LN10');
verifyNotWritable(Math, 'LN10');
verifyNotConfigurable(Math, 'LN10');
verifyProperty(Math, 'LN10', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, 'LN2');
verifyNotWritable(Math, 'LN2');
verifyNotConfigurable(Math, 'LN2');
verifyProperty(Math, 'LN2', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, 'LOG10E');
verifyNotWritable(Math, 'LOG10E');
verifyNotConfigurable(Math, 'LOG10E');
verifyProperty(Math, 'LOG10E', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, 'LOG2E');
verifyNotWritable(Math, 'LOG2E');
verifyNotConfigurable(Math, 'LOG2E');
verifyProperty(Math, 'LOG2E', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, 'PI');
verifyNotWritable(Math, 'PI');
verifyNotConfigurable(Math, 'PI');
verifyProperty(Math, 'PI', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, 'SQRT2');
verifyNotWritable(Math, 'SQRT2');
verifyNotConfigurable(Math, 'SQRT2');
verifyProperty(Math, 'SQRT2', {
writable: false,
enumerable: false,
configurable: false,
});

View File

@ -16,6 +16,8 @@ features: [Symbol.toStringTag]
assert.sameValue(Math[Symbol.toStringTag], 'Math');
verifyNotEnumerable(Math, Symbol.toStringTag);
verifyNotWritable(Math, Symbol.toStringTag);
verifyConfigurable(Math, Symbol.toStringTag);
verifyProperty(Math, Symbol.toStringTag, {
writable: false,
enumerable: false,
configurable: true,
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, "abs");
verifyWritable(Math, "abs");
verifyConfigurable(Math, "abs");
verifyProperty(Math, "abs", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, "acos");
verifyWritable(Math, "acos");
verifyConfigurable(Math, "acos");
verifyProperty(Math, "acos", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -7,6 +7,8 @@ includes: [propertyHelper.js]
es6id: 20.2.2.3
---*/
verifyNotEnumerable(Math, "acosh");
verifyWritable(Math, "acosh");
verifyConfigurable(Math, "acosh");
verifyProperty(Math, "acosh", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, "asin");
verifyWritable(Math, "asin");
verifyConfigurable(Math, "asin");
verifyProperty(Math, "asin", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -7,6 +7,8 @@ includes: [propertyHelper.js]
es6id: 20.2.2.5
---*/
verifyNotEnumerable(Math, "asinh");
verifyWritable(Math, "asinh");
verifyConfigurable(Math, "asinh");
verifyProperty(Math, "asinh", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, "atan");
verifyWritable(Math, "atan");
verifyConfigurable(Math, "atan");
verifyProperty(Math, "atan", {
writable: true,
enumerable: false,
configurable: true
});

View File

@ -11,6 +11,8 @@ info: |
includes: [propertyHelper.js]
---*/
verifyNotEnumerable(Math, "atan2");
verifyWritable(Math, "atan2");
verifyConfigurable(Math, "atan2");
verifyProperty(Math, "atan2", {
writable: true,
enumerable: false,
configurable: true,
});

Some files were not shown because too many files have changed in this diff Show More