Update WPT tests for embedded content
[WebKit-https.git] / LayoutTests / imported / w3c / web-platform-tests / html / semantics / embedded-content / media-elements / loading-the-media-resource / resource-selection-candidate-remove-no-listener.html
1 <!doctype html>
2 <title>removing the candidate source, no listener</title>
3 <script src="/resources/testharness.js"></script>
4 <script src="/resources/testharnessreport.js"></script>
5 <div id=log></div>
6 <script>
7 var v;
8 function createSource(src) {
9   var source = document.createElement('source');
10   source.src = src;
11   return source;
12 }
13 var t = async_test(function(t) {
14   v = document.createElement('video');
15   v.appendChild(createSource('resources/delayed-broken-video.py')); // invokes resource selection
16 });
17 </script>
18 <!-- now resource selection algorithm will continue its sync section (the </script> tag below provides a stable state) -->
19 <!-- the <source> is candidate -->
20 <!-- pointer is between the <source> and the end of the list -->
21 <script>
22 t.step(function() {
23   v.removeChild(v.firstChild); // just tests that we don't crash
24   onload = t.step_func(function() { t.done(); });
25 });
26 </script>