summaryrefslogtreecommitdiff
path: root/test/built-ins/WeakMap
diff options
context:
space:
mode:
authorMike Pennisi <mike@mikepennisi.com>2015-08-07 18:40:04 -0400
committerMike Pennisi <mike@mikepennisi.com>2015-08-07 20:02:44 -0400
commitd6bbbc9aed41c430d4d79f2f3c018a02665fb1d4 (patch)
tree775a75e53c851cb02c1c9067ddba21bec0d3ad15 /test/built-ins/WeakMap
parent9cb89a4e3c64e27ae385f3a65c26f69467f49314 (diff)
downloadqtdeclarative-testsuites-d6bbbc9aed41c430d4d79f2f3c018a02665fb1d4.tar.gz
Add tests for well-known Symbol: @@toStringTag
Diffstat (limited to 'test/built-ins/WeakMap')
-rw-r--r--test/built-ins/WeakMap/prototype/Symbol.toStringTag.js21
-rw-r--r--test/built-ins/WeakMap/prototype/Symbol.toStringTag/property-descriptor.js26
2 files changed, 21 insertions, 26 deletions
diff --git a/test/built-ins/WeakMap/prototype/Symbol.toStringTag.js b/test/built-ins/WeakMap/prototype/Symbol.toStringTag.js
new file mode 100644
index 000000000..a5fb0227b
--- /dev/null
+++ b/test/built-ins/WeakMap/prototype/Symbol.toStringTag.js
@@ -0,0 +1,21 @@
+// Copyright (C) 2015 the V8 project authors. All rights reserved.
+// This code is governed by the BSD license found in the LICENSE file.
+/*---
+es6id: 23.3.3.6
+description: >
+ `Symbol.toStringTag` property descriptor
+info: >
+ The initial value of the @@toStringTag property is the String value
+ "WeakMap".
+
+ This property has the attributes { [[Writable]]: false, [[Enumerable]]:
+ false, [[Configurable]]: true }.
+includes: [propertyHelper.js]
+features: [Symbol.toStringTag]
+---*/
+
+assert.sameValue(WeakMap.prototype[Symbol.toStringTag], 'WeakMap');
+
+verifyNotEnumerable(WeakMap.prototype, Symbol.toStringTag);
+verifyNotWritable(WeakMap.prototype, Symbol.toStringTag);
+verifyConfigurable(WeakMap.prototype, Symbol.toStringTag);
diff --git a/test/built-ins/WeakMap/prototype/Symbol.toStringTag/property-descriptor.js b/test/built-ins/WeakMap/prototype/Symbol.toStringTag/property-descriptor.js
deleted file mode 100644
index ef26cc6af..000000000
--- a/test/built-ins/WeakMap/prototype/Symbol.toStringTag/property-descriptor.js
+++ /dev/null
@@ -1,26 +0,0 @@
-// Copyright (C) 2015 the V8 project authors. All rights reserved.
-// This code is governed by the BSD license found in the LICENSE file.
-/*---
-es6id: 23.3.3.6
-description: "WeakMap#@@toStringTag value and writability"
-info: >
- WeakMap.prototype [ @@toStringTag ]
-
- The initial value of the @@toStringTag property is the String value "WeakMap".
-
- This property has the attributes { [[Writable]]: false, [[Enumerable]]: false,
- [[Configurable]]: true }.
-includes: [propertyHelper.js]
- ---*/
-
-var WeakMapProto = WeakMap.prototype;
-
-assert.sameValue(
- WeakMapProto[Symbol.toStringTag],
- 'WeakMap',
- 'The value of WeakMap.prototype[Symbol.toStringTag] is "WeakMap"'
-);
-
-verifyNotEnumerable(WeakMapProto, Symbol.toStringTag);
-verifyNotWritable(WeakMapProto, Symbol.toStringTag);
-verifyConfigurable(WeakMapProto, Symbol.toStringTag);