Closed Bug 1538809 Opened 5 years ago Closed 5 years ago

testing/marionette/listener.js unnecessarily pollutes test logs with "TypeError: reply[0] is undefined"

Categories

(Remote Protocol :: Marionette, defect)

Version 3
defect
Not set
normal

Tracking

(firefox68 fixed)

RESOLVED FIXED
mozilla68
Tracking Status
firefox68 --- fixed

People

(Reporter: Kwan, Assigned: Kwan)

References

Details

Attachments

(1 file)

So testing/marionette/listener.js has a nice check for whether or not reply is zero length. However even if it is, the registerSelf function continues on to try and access the outerWindowID property of reply[0]. It should just return after logging the error if the length is 0.

So it doesn't throw a TypeError when trying to access a property on undefined.

Pushed by atolfsen@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/bd35614065f6
[marionette] early return in listener.js registerSelf if reply array is empty. r=ato
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla68
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: