1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/js/src/tests/js1_5/extensions/regress-372309.js Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,47 @@ 1.4 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.7 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.8 + 1.9 +//----------------------------------------------------------------------------- 1.10 +var BUGNUMBER = 372309; 1.11 +var summary = 'Root new array objects'; 1.12 +var actual = 'No Crash'; 1.13 +var expect = 'No Crash'; 1.14 + 1.15 +function test() 1.16 +{ 1.17 + enterFunc ('test'); 1.18 + printBugNumber(BUGNUMBER); 1.19 + printStatus (summary); 1.20 + 1.21 + var width = 600; 1.22 + var height = 600; 1.23 + 1.24 + var img1canvas = document.createElement("canvas"); 1.25 + var img2canvas = document.createElement("canvas"); 1.26 + 1.27 + img1canvas.width = img2canvas.width = width; 1.28 + img1canvas.height = img2canvas.height = height; 1.29 + img1canvas.getContext("2d").getImageData(0, 0, width, height).data; 1.30 + img2canvas.getContext("2d").getImageData(0, 0, width, height).data; 1.31 + 1.32 + reportCompare(expect, actual, summary); 1.33 + gDelayTestDriverEnd = false; 1.34 + jsTestDriverEnd(); 1.35 + 1.36 + exitFunc ('test'); 1.37 +} 1.38 + 1.39 +if (typeof window != 'undefined') 1.40 +{ 1.41 + // delay test driver end 1.42 + gDelayTestDriverEnd = true; 1.43 + 1.44 + window.addEventListener("load", test, false); 1.45 +} 1.46 +else 1.47 +{ 1.48 + reportCompare(expect, actual, summary); 1.49 +} 1.50 +