1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/js/src/tests/supporting/test402-browser.js Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,24 @@ 1.4 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.5 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.6 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.7 + 1.8 +/* 1.9 + * Undo at least the damage done by taintArray so that the jstests 1.10 + * harness won't die. The properties added to Object.prototype by the various 1.11 + * tests have names that are less likely to cause trouble. 1.12 + */ 1.13 +setRestoreFunction((function () { 1.14 + var Array_indexOf = Array.prototype.indexOf; 1.15 + var Array_join = Array.prototype.join; 1.16 + var Array_push = Array.prototype.push; 1.17 + var Array_slice = Array.prototype.slice; 1.18 + var Array_sort = Array.prototype.sort; 1.19 + return function () { 1.20 + delete Array.prototype["0"]; 1.21 + Array.prototype.indexOf = Array_indexOf; 1.22 + Array.prototype.join = Array_join; 1.23 + Array.prototype.push = Array_push; 1.24 + Array.prototype.slice = Array_slice; 1.25 + Array.prototype.sort = Array_sort; 1.26 + }; 1.27 +}()));