blob: 6bbf2b8352139505718fa92f977f8e4492683de7 [file] [log] [blame]
<!doctype html>
<script>
function test()
{
if (window.testRunner) {
testRunner.dumpAsText();
testRunner.dumpNavigationPolicy();
testRunner.waitUntilDone();
var isMac = navigator.userAgent.search(/\bMac OS X\b/) != -1;
var submit = document.querySelector("#submit");
var evt = new MouseEvent("click", isMac ? { metaKey: true } : { ctrlKey: true });
submit.dispatchEvent(evt);
}
}
</script>
<body onload="test()">
<p>Tests that synthesizing ctrl-click on a submit button does not result in a new background tab.</p>
<form action="resources/notify-done.html">
<input type="text" name="foo" value="bar" />
<input type="submit" id="submit" />
</form>
</body>