1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
10 Object.defineProperty(Array.prototype, '0', {
11 get: function() { return 0; },
12 set: function() { throw "boom!"; }
15 Array.observe(arr, observer);
17 assertEquals(0, arr.length);
19 Object.deliverChangeRecords(observer);
20 assertEquals(1, records.length);
21 assertEquals('splice', records[0].type);
22 assertArrayEquals([1, 2], records[0].removed);