4 <script src="../../resources/js-test.js"></script>
7 testRunner.setShouldStayOnPageAfterHandlingBeforeUnload(true);
10 window.onload = function() {
11 window.location.href = "resources/does-not-exist.html";
12 setTimeout(function() {
13 shouldBeEqualToString("testEvent.returnValue", "");
18 window.addEventListener('beforeunload', function(event) {
20 shouldBe("testEvent.__proto__", "BeforeUnloadEvent.prototype");
21 return "not supposed to be assigned to returnValue";
27 description("Tests the returnValue attribute of the BeforeUnloadEvent from an event listener.");
28 self.jsTestIsAsync = true;