diff options
Diffstat (limited to 'js/src/tests/test262/built-ins/Array/prototype/push')
3 files changed, 13 insertions, 11 deletions
diff --git a/js/src/tests/test262/built-ins/Array/prototype/push/length.js b/js/src/tests/test262/built-ins/Array/prototype/push/length.js index d503ab3cfa..4df58993dd 100644 --- a/js/src/tests/test262/built-ins/Array/prototype/push/length.js +++ b/js/src/tests/test262/built-ins/Array/prototype/push/length.js @@ -25,10 +25,11 @@ info: | includes: [propertyHelper.js] ---*/ -assert.sameValue(Array.prototype.push.length, 1); - -verifyNotEnumerable(Array.prototype.push, 'length'); -verifyNotWritable(Array.prototype.push, 'length'); -verifyConfigurable(Array.prototype.push, 'length'); +verifyProperty(Array.prototype.push, "length", { + value: 1, + writable: false, + enumerable: false, + configurable: true +}); reportCompare(0, 0); diff --git a/js/src/tests/test262/built-ins/Array/prototype/push/name.js b/js/src/tests/test262/built-ins/Array/prototype/push/name.js index 42e2e96314..1590bdf48b 100644 --- a/js/src/tests/test262/built-ins/Array/prototype/push/name.js +++ b/js/src/tests/test262/built-ins/Array/prototype/push/name.js @@ -19,10 +19,11 @@ info: | includes: [propertyHelper.js] ---*/ -assert.sameValue(Array.prototype.push.name, "push"); - -verifyNotEnumerable(Array.prototype.push, "name"); -verifyNotWritable(Array.prototype.push, "name"); -verifyConfigurable(Array.prototype.push, "name"); +verifyProperty(Array.prototype.push, "name", { + value: "push", + writable: false, + enumerable: false, + configurable: true +}); reportCompare(0, 0); diff --git a/js/src/tests/test262/built-ins/Array/prototype/push/not-a-constructor.js b/js/src/tests/test262/built-ins/Array/prototype/push/not-a-constructor.js index 291b72867d..f709507f93 100644 --- a/js/src/tests/test262/built-ins/Array/prototype/push/not-a-constructor.js +++ b/js/src/tests/test262/built-ins/Array/prototype/push/not-a-constructor.js @@ -25,7 +25,7 @@ assert.sameValue(isConstructor(Array.prototype.push), false, 'isConstructor(Arra assert.throws(TypeError, () => { new Array.prototype.push(); -}, '`new Array.prototype.push()` throws TypeError'); +}); reportCompare(0, 0); |