| 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-1 |
| 6 |
description: > |
| 7 |
Object.defineProperties - 'P' is own existing data property |
| 8 |
(8.12.9 step 1 ) |
| 9 |
---*/ |
| 10 |
|
| 11 |
var obj = {}; |
| 12 |
Object.defineProperty(obj, "prop", { |
| 13 |
value: 11, |
| 14 |
configurable: false |
| 15 |
}); |
| 16 |
assert.throws(TypeError, function() { |
| 17 |
Object.defineProperties(obj, { |
| 18 |
prop: { |
| 19 |
value: 12, |
| 20 |
configurable: true |
| 21 |
} |
| 22 |
}); |
| 23 |
}); |