blob: 842921c4d0386b4071c5b9b9ffa12a29b99b9759 [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<script src="/js-test-resources/js-test.js"></script>
</head>
<body>
<a id="testLink" target="foo" rel="noreferrer" href="/navigation/resources/otherpage.html"></a>
<script>
description("Make sure that windows opened with 'noreferrer' are not targetable. If testing manually, you should see 2 tabs open.");
jsTestIsAsync = true;
if (window.testRunner)
testRunner.setCanOpenWindows();
onload = function() {
testLink.click();
setTimeout(function() {
w = open("/navigation/resources/otherpage.html", "foo"); // Should create a new window.
shouldBeEqualToString("w.location.href", "about:blank");
w.onload = function() {
if (window.testRunner)
shouldBe("testRunner.windowCount()", "3");
finishJSTest();
}
}, 100);
}
</script>
</body>
</html>