Skip to content

Commit

Permalink
Bug 1574488 [wpt PR 18499] - HTML: <img>'s historical progress events…
Browse files Browse the repository at this point in the history
…, a=testonly

Automatic update from web-platform-tests
HTML: <img>'s historical progress events

For whatwg/html#4842.

Co-Authored-By: Philip Jägenstedt <philipfoolip.org>
--

wpt-commits: 76987cb3bb890c8691773ee7773cd150559ce594
wpt-pr: 18499

UltraBlame original commit: 8bab9a7565f280ee038dda3708354cfddcbf1016
  • Loading branch information
marco-c committed Oct 4, 2019
1 parent eac2ed6 commit c0478fb
Showing 1 changed file with 16 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
async_test(t => {
const img = new Image();
t.add_cleanup(() => img.remove());
img.onloadstart = img.onprogress = img.onloadend = t.unreached_func("progress event fired");
img.onload = t.step_func_done(e => {
assert_true(e instanceof Event);
assert_false(e instanceof ProgressEvent);
});
img.src = "/images/rrgg-256x256.png";
document.body.append(img);
}, "<img> does not support ProgressEvent or loadstart/progress/loadend");

test(t => {
assert_equals(document.body.onloadend, undefined);
assert_equals(window.onloadend, undefined);
}, "onloadend is not exposed");

0 comments on commit c0478fb

Please sign in to comment.