Debian Codegraph @

tests/auto/qml/ecmascripttests/test262/test/built-ins/Object/defineProperties/15.2.3.7-6-a-2.js

raw
1 // Copyright (c) 2012 Ecma International. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
3
4 /*---
5 es5id: 15.2.3.7-6-a-2
6 description: >
7 Object.defineProperties - 'P' is inherited data property (8.12.9
8 step 1 )
9 includes: [propertyHelper.js]
10 ---*/
11
12 var proto = {};
13 Object.defineProperty(proto, "prop", {
14 value: 11,
15 configurable: false
16 });
17 var Con = function() {};
18 Con.prototype = proto;
19
20 var obj = new Con();
21
22 Object.defineProperties(obj, {
23 prop: {
24 value: 12,
25 configurable: true
26 }
27 });
28
29 verifyEqualTo(obj, "prop", 12);
30
31 verifyNotWritable(obj, "prop");
32
33 verifyNotEnumerable(obj, "prop");
34
35 verifyConfigurable(obj, "prop");