Closed Bug 1274924 Opened 8 years ago Closed 8 years ago

GeckoDriver.getTextFromDialog() throws "TypeError: can't convert null to object"

Categories

(Remote Protocol :: Marionette, defect)

47 Branch
defect
Not set
normal

Tracking

(firefox47 affected, firefox48 fixed, firefox49 fixed)

RESOLVED FIXED
mozilla49
Tracking Status
firefox47 --- affected
firefox48 --- fixed
firefox49 --- fixed

People

(Reporter: jlorenzo, Assigned: jlorenzo)

Details

Attachments

(1 file)

I don't have a reduced test case yet, but I can always repro this failure with this test[1]. If I understand correctly, under a certain set of conditions, `this.dialog.ui` doesn't have a value yet[2]. I proposed a workaround for the Selenium JS client at [3].

I believe, we can just extend the if condition just above[4] to make sure ui is not equal to null. I'll give it a try.

[1] https://github.com/fxbox/foxbox/blob/42c347565b2cbdfd9f453b7b78b234effe841ee3/test/selenium/sessions_ui_test.js#L99 . Failed execution at: https://travis-ci.org/fxbox/foxbox/jobs/131700352#L1482
[2] https://dxr.mozilla.org/mozilla-central/rev/16663eb3dcfa759f25b5e27b101bc79270c156f2/testing/marionette/driver.js#2513
[3] https://github.com/SeleniumHQ/selenium/pull/2137
[4] https://dxr.mozilla.org/mozilla-central/rev/16663eb3dcfa759f25b5e27b101bc79270c156f2/testing/marionette/driver.js#2508
The following patch works for me locally. What would be the best place to add a test :AutomatedTester?
Comment on attachment 8755382 [details]
MozReview Request: Bug 1274924 - GeckoDriver.getTextFromDialog() throws "TypeError: can't convert null to object" r=AutomatedTester

https://reviewboard.mozilla.org/r/54580/#review51196
Attachment #8755382 - Flags: review?(dburns) → review+
https://hg.mozilla.org/mozilla-central/rev/370ee31f8d97
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla49
Product: Testing → Remote Protocol
You need to log in before you can comment on or make changes to this bug.