Closed Bug 977893 Opened 10 years ago Closed 10 years ago

getCurrentUrl does not match behaviour of the WebDriver spec

Categories

(Remote Protocol :: Marionette, defect, P3)

x86
macOS
defect

Tracking

(Not tracked)

RESOLVED FIXED
mozilla35

People

(Reporter: automatedtester, Assigned: automatedtester)

References

(Blocks 1 open bug, )

Details

(Keywords: pi-marionette-spec)

Attachments

(2 files, 2 obsolete files)

when calling getCurrentUrl we must return the top level browsing context url not the url of the current frame.
Assignee: nobody → ato
Status: NEW → ASSIGNED
Attaching a first stab at a fix for this.  I'm not sure how to reliably access the parent frame of cross-domain documents.  Can we override the security permissions imposed by the DOM somehow?
Attachment #8392933 - Flags: review?(dburns)
Attachment #8392933 - Flags: review?(dburns) → feedback?(dburns)
Attached patch half completed getCurrentUrl (obsolete) — Splinter Review
Assignee: ato → dburns
To get the top level context we need to work mainly in the server code. I have half done the patch, it will need more testing

I would make sure we test on b2g because this may have unforeseen circumstances...
Assignee: dburns → ato
That approach looks more sane to me, thanks!
Attachment #8392933 - Flags: feedback?(dburns)
Whiteboard: [spec]
Priority: -- → P3
Whiteboard: [spec]
It looks like patch attached by David Burns is already in master branch. Should it be closed?
Sorry, I misunderstood the diff.
Assignee: ato → dburns
Attachment #8393227 - Attachment is obsolete: true
Attachment #8477783 - Attachment is obsolete: true
Comment on attachment 8483727 [details] [diff] [review]
getCurrentUrl in marionette should return the url for the top level document

Review of attachment 8483727 [details] [diff] [review]:
-----------------------------------------------------------------

I'm a little sad about disabling test_switch_frame on b2g, but I guess that kind of in-process frame switching isn't common there (or maybe never exists at all).
Attachment #8483727 - Flags: review?(jgriffin) → review+
https://hg.mozilla.org/mozilla-central/rev/1d1bca9ca7a3
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla35
Product: Testing → Remote Protocol
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: