diff options
Diffstat (limited to 'testing/web-platform/tests/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-invoke-insert-fragment-into-document.html')
-rw-r--r-- | testing/web-platform/tests/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-invoke-insert-fragment-into-document.html | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/testing/web-platform/tests/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-invoke-insert-fragment-into-document.html b/testing/web-platform/tests/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-invoke-insert-fragment-into-document.html new file mode 100644 index 0000000000..5d4c32f670 --- /dev/null +++ b/testing/web-platform/tests/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-invoke-insert-fragment-into-document.html @@ -0,0 +1,22 @@ +<!doctype html> +<title>NOT invoking resource selection by inserting document fragment into a document</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<div id=log></div> +<script> +var v; +var t = async_test(function(t) { + v = document.createElement('video'); + var fragment = document.createDocumentFragment(); + fragment.appendChild(v); + assert_equals(v.networkState, v.NETWORK_EMPTY, 'networkState after fragment.appendChild(v)'); + document.body.appendChild(fragment); + assert_equals(v.networkState, v.NETWORK_EMPTY, 'networkState after document.body.appendChild(fragment)'); +}); +</script> +<script> +t.step(function() { + assert_equals(v.networkState, v.NETWORK_EMPTY, 'networkState in separate script'); + t.done(); +}); +</script> |