summaryrefslogtreecommitdiff
path: root/test/built-ins/Object/defineProperty/15.2.3.6-4-112.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/built-ins/Object/defineProperty/15.2.3.6-4-112.js')
-rw-r--r--test/built-ins/Object/defineProperty/15.2.3.6-4-112.js47
1 files changed, 24 insertions, 23 deletions
diff --git a/test/built-ins/Object/defineProperty/15.2.3.6-4-112.js b/test/built-ins/Object/defineProperty/15.2.3.6-4-112.js
index 9fecb9176..993240de3 100644
--- a/test/built-ins/Object/defineProperty/15.2.3.6-4-112.js
+++ b/test/built-ins/Object/defineProperty/15.2.3.6-4-112.js
@@ -10,33 +10,34 @@ description: >
Object.defineProperty - 'name' and 'desc' are accessor properties,
name.[[Set]] is undefined and desc.[[Set]] is function (8.12.9
step 12)
-includes:
- - runTestCase.js
- - accessorPropertyAttributesAreCorrect.js
+includes: [propertyHelper.js]
---*/
-function testcase() {
- var obj = {};
+var obj = {};
- function getFunc() {
- return 10;
- }
+function getFunc() {
+ return 10;
+}
- Object.defineProperty(obj, "foo", {
- set: undefined,
- get: getFunc,
- enumerable: true,
- configurable: true
- });
+Object.defineProperty(obj, "foo", {
+ set: undefined,
+ get: getFunc,
+ enumerable: true,
+ configurable: true
+});
- function setFunc(value) {
- obj.setVerifyHelpProp = value;
- }
+function setFunc(value) {
+ obj.setVerifyHelpProp = value;
+}
- Object.defineProperty(obj, "foo", {
- set: setFunc
- });
- return accessorPropertyAttributesAreCorrect(obj, "foo", getFunc, setFunc, "setVerifyHelpProp", true, true);
- }
-runTestCase(testcase);
+Object.defineProperty(obj, "foo", {
+ set: setFunc
+});
+verifyEqualTo(obj, "foo", getFunc());
+
+verifyWritable(obj, "foo", "setVerifyHelpProp");
+
+verifyEnumerable(obj, "foo");
+
+verifyConfigurable(obj, "foo");