15.2.3.7-6-a-97.js (674B)
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-97 6 description: > 7 Object.defineProperties - 'P' is data property, P.writable and 8 properties.writable are different values (8.12.9 step 12) 9 includes: [propertyHelper.js] 10 ---*/ 11 12 13 var obj = {}; 14 15 Object.defineProperty(obj, "foo", { 16 value: 100, 17 enumerable: true, 18 writable: false, 19 configurable: true 20 }); 21 22 Object.defineProperties(obj, { 23 foo: { 24 writable: true 25 } 26 }); 27 28 verifyProperty(obj, "foo", { 29 value: 100, 30 writable: true, 31 enumerable: true, 32 configurable: true, 33 }); 34 35 reportCompare(0, 0);