Index: LayoutTests/fast/html/imports/import-remove.html |
diff --git a/LayoutTests/fast/html/imports/import-remove.html b/LayoutTests/fast/html/imports/import-remove.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..4675a66623251d3a1e407f8eac7ac401b442b3ac |
--- /dev/null |
+++ b/LayoutTests/fast/html/imports/import-remove.html |
@@ -0,0 +1,27 @@ |
+<!DOCTYPE html> |
+<html> |
+<script src="../../js/resources/js-test-pre.js"></script> |
+<head> |
+<link id="hello" rel="import" href="resources/hello.html"> |
+</head> |
+<body> |
+<script> |
+jsTestIsAsync = true; |
+var hello = document.getElementById("hello"); |
+shouldBeNonNull("hello.import"); |
+ |
+debug("Node removal should make import deleted."); |
+hello.parentNode.removeChild(hello); |
+shouldBeNull("hello.import"); |
+ |
+debug("Re-inserting it shouldn't help."); |
+document.head.appendChild(hello); |
+window.setTimeout(function() { |
+ shouldBeNull("hello.import"); |
+ finishJSTest(); |
+}, 0); |
+ |
+</script> |
+<script src="../../js/resources/js-test-post.js"></script> |
+</body> |
+</html> |