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.
4
5function nope() { return false; }
6var a = [ 1, 2, 3 ];
7Object.seal(a);
8Object.isSealed = nope;
9
10assertThrows(function() { a.pop(); }, TypeError);
11assertThrows(function() { a.push(5); }, TypeError);
12assertThrows(function() { a.shift(); }, TypeError);
13assertThrows(function() { a.unshift(5); }, TypeError);
14assertThrows(function() { a.splice(0, 1); }, TypeError);
15