1 <!DOCTYPE HTML PUBLIC
"-//IETF//DTD HTML//EN">
4 <script src=
"../../resources/js-test.js"></script>
7 description("This test checks behavior of drawImage on a canvas that failed to allocate its backing store. This test passes by not crashing.");
8 var canvas1
= document
.createElement("canvas");
9 var ctx1
= canvas1
.getContext('2d');
10 var canvas2
= document
.createElement("canvas");
11 // Terapixel canvas should fail to allocate
12 canvas2
.width
= 1000000;
13 canvas2
.height
= 1000000;
14 var ctx2
= canvas2
.getContext('2d');
15 ctx2
.drawImage(canvas1
, 0, 0);