blob: c1b3a29e1f0cfd0627fb5c12f770acfd8d9c7317 [file] [log] [blame]
<!DOCTYPE html>
<title>Test for loading invalid multipart image</title>
<script src="../../../resources/testharness.js"></script>
<script src="../../../resources/testharnessreport.js"></script>
<script>
async_test(t => {
const img = document.createElement('img');
img.onload = t.step_func(() => {
assert_unreached('The image should not be loaded');
});
img.onerror = t.step_func_done((e) => {
assert_equals(e.type, 'error');
});
img.src = 'resources/invalid-multipart-image.php';
}, 'invalid multipart image should not be loaded');
</script>