Closed Bug 1500240 Opened 6 years ago Closed 6 years ago

Stop relying on getElementByID for anonymous search-suggestions-change-settings element in test

Categories

(Firefox :: Search, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
Firefox 64
Tracking Status
firefox64 --- fixed

People

(Reporter: bgrins, Assigned: bgrins)

References

Details

Attachments

(1 file)

This returns null in browser.xhtml: https://searchfox.org/mozilla-central/rev/c56977420df7a1b692ce0f7e499ddb364d9fd7b2/browser/base/content/test/urlbar/browser_urlbarSearchSuggestions_opt-out.js#58. I was surprised that this works at all inside of XBL anon content in browser.xul, but I think it's happening at https://searchfox.org/mozilla-central/rev/c56977420df7a1b692ce0f7e499ddb364d9fd7b2/dom/xul/XULDocument.cpp#929. This is done only in the test (https://searchfox.org/mozilla-central/search?q=search-suggestions-change-settings&path=) so I think this would be safe to use `document.getAnonymousElementByAttribute` instead.
Pushed by bgrinstead@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/53abc33e3e38 Use getAnonymousElementByAttribute instead of getElementByID for XBL anonymous search element;r=dao
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 64
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: