Closed Bug 1874921 Opened 1 year ago Closed 1 year ago

Replace usages of SearchService.addOpenSearchEngine in test code with SearchTestUtils.promiseNewSearchEngine.

Categories

(Firefox :: Search, task, P2)

task

Tracking

()

RESOLVED FIXED
124 Branch
Tracking Status
firefox124 --- fixed

People

(Reporter: standard8, Assigned: standard8)

Details

Attachments

(2 files)

I want to update SearchService.addOpenSearchEngine to simplify the loading mechanism further. To make it simpler to do, I want to transition our tests to use SearchTestUtils.promiseNewSearchEngine where they are not explicitly testing the API.

This way, it will make it easier to alter the addOpenSearchEngine function signature as most of the changes for tests will be hidden in SearchTestUtils.promiseNewSearchEngine.

Note: ideally in future we'll improve the naming of the test function - I've filed bug 1874917 for that.

This test was ensuring that we correctly handle invalid searchForm urls.
We can replace that with a simple extension of our test_opensearch tests.

Depends on D198459

Depends on D198459

This replaces all the test instances, apart from some of the OpenSearch tests where we need to test
the API directly.

Depends on D198722

Pushed by mbanner@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/1aa8a11ca885 Replace browser_483086.js with an xpcshell-test. r=search-reviewers,mcheang https://hg.mozilla.org/integration/autoland/rev/9572d20d38b7 Replace usages of SearchService.addOpenSearchEngine in test code with SearchTestUtils.promiseNewSearchEngine. r=search-reviewers,mcheang
Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 124 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: