OLD | NEW |
1 <body> | 1 <body> |
2 <script> | 2 <script> |
3 if (window.testRunner) { | 3 if (window.testRunner) |
4 testRunner.dumpAsText(); | 4 testRunner.dumpAsText(); |
5 testRunner.dumpResourceLoadCallbacks(); | |
6 } | |
7 | 5 |
8 var xhrs = new Array(3); | 6 var xhrs = new Array(3); |
| 7 var abortCount = 0; |
9 for (var i = 0; i < 3; i++) { | 8 for (var i = 0; i < 3; i++) { |
10 xhrs[i] = new XMLHttpRequest(); | 9 xhrs[i] = new XMLHttpRequest(); |
11 xhrs[i].open("POST", 'resources/empty.txt', true); | 10 xhrs[i].onabort = function() { |
| 11 abortCount++; |
| 12 } |
| 13 xhrs[i].open("POST", 'resources/empty.txt', true); |
12 xhrs[i].send(i); | 14 xhrs[i].send(i); |
13 } | 15 } |
14 | 16 |
15 for (var i = 0; i < 3; i++) | 17 for (var i = 0; i < 3; i++) |
16 xhrs[i].abort(); | 18 xhrs[i].abort(); |
| 19 |
| 20 document.body.appendChild(document.createTextNode(abortCount == 3 ? "PASS" : "FA
IL")); |
17 </script> | 21 </script> |
18 </body> | 22 </body> |
OLD | NEW |