Closed
Bug 865627
Opened 11 years ago
Closed 11 years ago
Change exists method for handling Lookup expression that does not exist
Categories
(Testing Graveyard :: Mozmill, defect)
Testing Graveyard
Mozmill
Tracking
(Not tracked)
RESOLVED
DUPLICATE
of bug 860659
People
(Reporter: daniela.p98911, Assigned: daniela.p98911)
References
Details
(Keywords: testcase)
Attachments
(2 files)
585 bytes,
patch
|
Details | Diff | Splinter Review | |
548 bytes,
application/javascript
|
Details |
After investigating bug 864375, we have found out that exists method in mozelement does not handle the case where the lookup expression does not exist and an exception is thrown from elementslib.Lookup. In Mozmill 1.5.21 we had this method: https://github.com/mozilla/mozmill/blob/hotfix-1.5/mozmill/mozmill/extension/resource/modules/elementslib.js#L417 that handled an element that did not exist. In Mozmill 2.0 when trying to get the element https://github.com/mozilla/mozmill/blob/master/mozmill/mozmill/extension/resource/driver/mozelement.js#L126 (this.element from __defineGetter__ method) we are calling again elementslib.Lookup which will cause an exception since the element does not exist on the page.
Assignee | ||
Updated•11 years ago
|
Whiteboard: [mozmill-2.0?]
Assignee | ||
Comment 1•11 years ago
|
||
Modified exists in mozelement.js returns true if the this.element exists or false in case the element does not exist or an error is thrown when searching for the element.
Assignee: nobody → dpetrovici
Status: NEW → ASSIGNED
Attachment #741794 -
Flags: review?(hskupin)
Attachment #741794 -
Flags: review?(dave.hunt)
Comment 2•11 years ago
|
||
Comment on attachment 741794 [details] [diff] [review] patch v1.0 Review of attachment 741794 [details] [diff] [review]: ----------------------------------------------------------------- Before we review this please make sure to add a proper test for this particular case.
Attachment #741794 -
Flags: review?(hskupin)
Attachment #741794 -
Flags: review?(dave.hunt)
Comment 3•11 years ago
|
||
I wanna see a testcase here given that I can't see how an exception can be raised by the element getter.
Keywords: testcase-wanted
Comment 4•11 years ago
|
||
Comment 5•11 years ago
|
||
So this is not something we should wallpaper in mozelement.js. The real problem lays in elementslib.js and has to be fixed in that file.
Keywords: testcase-wanted → testcase
Comment 6•11 years ago
|
||
This is actually a dupe of bug 860659.
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → DUPLICATE
Whiteboard: [mozmill-2.0?]
Updated•8 years ago
|
Product: Testing → Testing Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•