<script> | |
if (window.testRunner) { | |
testRunner.dumpAsText(); | |
testRunner.waitUntilDone(); | |
} | |
function loaded() { | |
var image = document.body.getElementsByTagName('img')[0]; | |
alert(image.width > 0 ? 'PASS' : 'FAIL'); | |
if (window.testRunner) | |
testRunner.notifyDone(); | |
} | |
</script> | |
This image should load:<br> | |
<img crossorigin="anonymous" src="resources/abe.png" onload="loaded()"> |