| // Copyright (c) 2012 Ecma International. All rights reserved. |
| // This code is governed by the BSD license found in the LICENSE file. |
| ES5 Attributes - fail to update [[Enumerable]] attribute of |
| accessor property ([[Get]] is a Function, [[Set]] is a Function, |
| [[Enumerable]] is true, [[Configurable]] is false) to different |
| var getFunc = function () { |
| var verifySetFunc = "data"; |
| var setFunc = function (value) { |
| Object.defineProperty(obj, "prop", { |
| var desc1 = Object.getOwnPropertyDescriptor(obj, "prop"); |
| assert.throws(TypeError, function() { |
| Object.defineProperty(obj, "prop", { |
| var desc2 = Object.getOwnPropertyDescriptor(obj, "prop"); |
| assert(result1, 'result1 !== true'); |
| assert(result2, 'result2 !== true'); |
| assert.sameValue(desc1.enumerable, true, 'desc1.enumerable'); |
| assert.sameValue(desc2.enumerable, true, 'desc2.enumerable'); |