summaryrefslogtreecommitdiffstats
path: root/js/src/tests/test262/built-ins/String/prototype/endsWith
diff options
context:
space:
mode:
Diffstat (limited to 'js/src/tests/test262/built-ins/String/prototype/endsWith')
-rw-r--r--js/src/tests/test262/built-ins/String/prototype/endsWith/length.js14
-rw-r--r--js/src/tests/test262/built-ins/String/prototype/endsWith/name.js14
-rw-r--r--js/src/tests/test262/built-ins/String/prototype/endsWith/not-a-constructor.js2
3 files changed, 13 insertions, 17 deletions
diff --git a/js/src/tests/test262/built-ins/String/prototype/endsWith/length.js b/js/src/tests/test262/built-ins/String/prototype/endsWith/length.js
index d5040bab96..edfe1585f0 100644
--- a/js/src/tests/test262/built-ins/String/prototype/endsWith/length.js
+++ b/js/src/tests/test262/built-ins/String/prototype/endsWith/length.js
@@ -13,13 +13,11 @@ includes: [propertyHelper.js]
features: [String.prototype.endsWith]
---*/
-assert.sameValue(
- String.prototype.endsWith.length, 1,
- 'The value of `String.prototype.endsWith.length` is `1`'
-);
-
-verifyNotEnumerable(String.prototype.endsWith, 'length');
-verifyNotWritable(String.prototype.endsWith, 'length');
-verifyConfigurable(String.prototype.endsWith, 'length');
+verifyProperty(String.prototype.endsWith, "length", {
+ value: 1,
+ writable: false,
+ enumerable: false,
+ configurable: true
+});
reportCompare(0, 0);
diff --git a/js/src/tests/test262/built-ins/String/prototype/endsWith/name.js b/js/src/tests/test262/built-ins/String/prototype/endsWith/name.js
index d4aa6ee5f5..27b35d7bf3 100644
--- a/js/src/tests/test262/built-ins/String/prototype/endsWith/name.js
+++ b/js/src/tests/test262/built-ins/String/prototype/endsWith/name.js
@@ -13,13 +13,11 @@ includes: [propertyHelper.js]
features: [String.prototype.endsWith]
---*/
-assert.sameValue(
- String.prototype.endsWith.name, 'endsWith',
- 'The value of `String.prototype.endsWith.name` is `"endsWith"`'
-);
-
-verifyNotEnumerable(String.prototype.endsWith, 'name');
-verifyNotWritable(String.prototype.endsWith, 'name');
-verifyConfigurable(String.prototype.endsWith, 'name');
+verifyProperty(String.prototype.endsWith, "name", {
+ value: "endsWith",
+ writable: false,
+ enumerable: false,
+ configurable: true
+});
reportCompare(0, 0);
diff --git a/js/src/tests/test262/built-ins/String/prototype/endsWith/not-a-constructor.js b/js/src/tests/test262/built-ins/String/prototype/endsWith/not-a-constructor.js
index 2112ea842d..52076bb384 100644
--- a/js/src/tests/test262/built-ins/String/prototype/endsWith/not-a-constructor.js
+++ b/js/src/tests/test262/built-ins/String/prototype/endsWith/not-a-constructor.js
@@ -29,7 +29,7 @@ assert.sameValue(
assert.throws(TypeError, () => {
new String.prototype.endsWith();
-}, '`new String.prototype.endsWith()` throws TypeError');
+});
reportCompare(0, 0);