Debian Codegraph @

js/src/tests/test262/built-ins/Object/defineProperty/15.2.3.6-4-277.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.6-4-277
6 description: >
7 Object.defineProperty - 'O' is an Array, 'name' is generic
8 property that won't exist on 'O', and 'desc' is data descriptor,
9 test 'name' is defined in 'O' with all correct attribute values
10 (15.4.5.1 step 5)
11 includes: [propertyHelper.js]
12 ---*/
13
14
15 var arrObj = [];
16
17 Object.defineProperty(arrObj, "property", {
18 value: 12,
19 writable: true,
20 enumerable: true,
21 configurable: true
22 });
23
24 verifyProperty(arrObj, "property", {
25 value: 12,
26 writable: true,
27 enumerable: true,
28 configurable: true,
29 });
30
31 reportCompare(0, 0);