diff options
Diffstat (limited to 'js/src/tests/test262/built-ins/Set/prototype/clear')
3 files changed, 13 insertions, 11 deletions
diff --git a/js/src/tests/test262/built-ins/Set/prototype/clear/length.js b/js/src/tests/test262/built-ins/Set/prototype/clear/length.js index 84e1dd1146..b275b85aa1 100644 --- a/js/src/tests/test262/built-ins/Set/prototype/clear/length.js +++ b/js/src/tests/test262/built-ins/Set/prototype/clear/length.js @@ -10,10 +10,11 @@ description: > includes: [propertyHelper.js] ---*/ -assert.sameValue(Set.prototype.clear.length, 0, "The value of `Set.prototype.clear.length` is `0`"); - -verifyNotEnumerable(Set.prototype.clear, "length"); -verifyNotWritable(Set.prototype.clear, "length"); -verifyConfigurable(Set.prototype.clear, "length"); +verifyProperty(Set.prototype.clear, "length", { + value: 0, + writable: false, + enumerable: false, + configurable: true +}); reportCompare(0, 0); diff --git a/js/src/tests/test262/built-ins/Set/prototype/clear/name.js b/js/src/tests/test262/built-ins/Set/prototype/clear/name.js index 722a8af8f1..f6c25d3f21 100644 --- a/js/src/tests/test262/built-ins/Set/prototype/clear/name.js +++ b/js/src/tests/test262/built-ins/Set/prototype/clear/name.js @@ -10,10 +10,11 @@ description: > includes: [propertyHelper.js] ---*/ -assert.sameValue(Set.prototype.clear.name, "clear", "The value of `Set.prototype.clear.name` is `'clear'`"); - -verifyNotEnumerable(Set.prototype.clear, "name"); -verifyNotWritable(Set.prototype.clear, "name"); -verifyConfigurable(Set.prototype.clear, "name"); +verifyProperty(Set.prototype.clear, "name", { + value: "clear", + writable: false, + enumerable: false, + configurable: true +}); reportCompare(0, 0); diff --git a/js/src/tests/test262/built-ins/Set/prototype/clear/not-a-constructor.js b/js/src/tests/test262/built-ins/Set/prototype/clear/not-a-constructor.js index 16f0ebd97c..26e25a8d0f 100644 --- a/js/src/tests/test262/built-ins/Set/prototype/clear/not-a-constructor.js +++ b/js/src/tests/test262/built-ins/Set/prototype/clear/not-a-constructor.js @@ -25,7 +25,7 @@ assert.sameValue(isConstructor(Set.prototype.clear), false, 'isConstructor(Set.p assert.throws(TypeError, () => { let s = new Set([]); new s.clear(); -}, '`let s = new Set([]); new s.clear()` throws TypeError'); +}); reportCompare(0, 0); |