<body onload="test()">
FAILURE
<script>
if (window.testRunner)
    testRunner.dumpAsText();
function test()
{
    document.write("<br>Test 1<br>File in URL: " + leafName(document.URL) + "<br><script src='resources/external-script-URL-location.js'></scr" + "ipt>");
}

function leafName(url) {
    var tokens = new Array();
    tokens = url.split('/');
    var len = tokens.length;
    return tokens[len-1];
}

</script>
</body>
