RESOLVED FIXED 63285
Add a test with a single <source> element
https://bugs.webkit.org/show_bug.cgi?id=63285
Summary Add a test with a single <source> element
Eric Carlson
Reported 2011-06-23 13:56:18 PDT
We should test that a <video> element with a single <source> element loads correctly.
Attachments
Proposed patch. (2.89 KB, patch)
2011-06-23 14:04 PDT, Eric Carlson
no flags
Updated patch (2.91 KB, patch)
2011-06-23 14:30 PDT, Eric Carlson
simon.fraser: review+
Eric Carlson
Comment 1 2011-06-23 14:04:09 PDT
Created attachment 98395 [details] Proposed patch.
Alexis Menard (darktears)
Comment 2 2011-06-23 14:13:11 PDT
Comment on attachment 98395 [details] Proposed patch. View in context: https://bugs.webkit.org/attachment.cgi?id=98395&action=review > LayoutTests/media/video-single-source.html:27 > + // The second source is bogus and won't load, but it should never be processed. But the name of the tests is "single source". Perhaps you should name it "Single valid source". > LayoutTests/media/video-single-source.html:36 > + waitForEvent('error', errorEvent); You say that "The second source is bogus and won't load, but it should never be processed." -> processed you mean rendered or whatever, because here you expect an error on the last source as the spec says. I'm nitpicking.
Eric Carlson
Comment 3 2011-06-23 14:23:23 PDT
(In reply to comment #2) > (From update of attachment 98395 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=98395&action=review > > > LayoutTests/media/video-single-source.html:27 > > + // The second source is bogus and won't load, but it should never be processed. > > But the name of the tests is "single source". Perhaps you should name it "Single valid source". > OK. > > LayoutTests/media/video-single-source.html:36 > > + waitForEvent('error', errorEvent); > > You say that "The second source is bogus and won't load, but it should never be processed." -> processed you mean rendered or whatever, because here you expect an error on the last source as the spec says. I'm nitpicking. Not quite. If HTMLMediaElement processes the <source> at all, it will pass the url to the media engine based on the MIME type. The file doesn't exist so the load will fail and an error event will be posted, and errorEvent will fail the test with a message about what went wrong.
Eric Carlson
Comment 4 2011-06-23 14:30:46 PDT
Created attachment 98406 [details] Updated patch
Eric Carlson
Comment 5 2011-06-23 14:37:16 PDT
Note You need to log in before you can comment on or make changes to this bug.