<body> | |
<script> | |
if (window.testRunner) | |
testRunner.dumpAsText(); | |
var xhrs = new Array(3); | |
var abortCount = 0; | |
for (var i = 0; i < 3; i++) { | |
xhrs[i] = new XMLHttpRequest(); | |
xhrs[i].onabort = function() { | |
abortCount++; | |
} | |
xhrs[i].open("POST", 'resources/empty.txt', true); | |
xhrs[i].send(i); | |
} | |
for (var i = 0; i < 3; i++) | |
xhrs[i].abort(); | |
document.body.appendChild(document.createTextNode(abortCount == 3 ? "PASS" : "FAIL")); | |
</script> | |
</body> |