Closed
Bug 1361454
Opened 9 years ago
Closed 8 years ago
With `get` command a previously set `beforeunload` handler is not triggered
Categories
(Remote Protocol :: Marionette, defect, P3)
Tracking
(Not tracked)
RESOLVED
INVALID
People
(Reporter: whimboo, Unassigned)
Details
As seen while working on bug 1357634, the get command does not invoke the tab modal alert, which asks the user to leave or stay on the current page. It works fine with `click`, but fails with `get`.
Maybe this happens because of the way how we set the new url:
> curContainer.frame.location = url;
It's something we might investigate and get fixed at some point.
Example code:
def test_navigate_aborted_with_onbeforeunload(self):
page = self.marionette.absolute_url("beforeunload.html")
self.marionette.navigate(page)
self.marionette.navigate(self.test_page_remote)
# navigate returns immediately when a beforeunload handler is invoked
alert = self.marionette.switch_to_alert()
alert.dismiss()
Updated•8 years ago
|
Priority: -- → P3
| Reporter | ||
Comment 1•8 years ago
|
||
As by the spec none of the navigation commands should handle the beforeunload event, but it is ignored/disabled by default. See bug 1434872.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → INVALID
Updated•3 years ago
|
Product: Testing → Remote Protocol
You need to log in
before you can comment on or make changes to this bug.
Description
•