Index: third_party/WebKit/LayoutTests/http/tests/navigation/targeted-navigation-in-unload-handler.html |
diff --git a/third_party/WebKit/LayoutTests/http/tests/navigation/targeted-navigation-in-unload-handler.html b/third_party/WebKit/LayoutTests/http/tests/navigation/targeted-navigation-in-unload-handler.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..69a4336c4c7ba96d367ec867fcecb5337788c5e3 |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/http/tests/navigation/targeted-navigation-in-unload-handler.html |
@@ -0,0 +1,30 @@ |
+<html> |
+<head> |
+<script src="/resources/testharness.js"></script> |
+<script src="/resources/testharnessreport.js"></script> |
+<script> |
+var test = async_test("Tests that a navigation in the unload handler succeeds if it's targeting a frame that's not being unloaded."); |
+function complete() { |
+ test.done(); |
+} |
+ |
+window.onload = function() { |
+ var frame = document.createElement('iframe'); |
+ document.body.appendChild(frame); |
+ |
+ var sibling = document.createElement('iframe'); |
+ document.body.appendChild(sibling); |
+ |
+ frame.contentWindow.onunload = function () { |
+ sibling.contentWindow.location.href = 'resources/targeted-navigation-in-unload-handler-subframe.html'; |
+ } |
+ |
+ setTimeout(function() { |
+ frame.contentWindow.location.assign('about:blank'); |
+ }, 100); |
+} |
+</script> |
+</head> |
+<body> |
+</body> |
+</html> |