Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!DOCTYPE html>
<meta charset="utf-8">
<title>An image is complete after a malformed URL error</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>
"use strict";
async_test(t => {
const img = document.createElement("img");
img.src = "http://malformed:url";
assert_false(img.complete);
img.onload = img.onerror = t.step_func_done(event => {
assert_equals(event.type, "error");
assert_true(img.complete);
});
}, "src malformed URL");
</script>