Closed Bug 1582944 Opened 1 year ago Closed 10 months ago

Convert cache based tests to modern config

Categories

(Firefox :: Search, task, P2)

task
Points:
5

Tracking

()

RESOLVED FIXED
Firefox 72
Iteration:
72.3 - Nov 18 - Dec 1
Tracking Status
firefox72 --- fixed

People

(Reporter: daleharvey, Assigned: standard8)

References

Details

Attachments

(4 files)

In https://bugzilla.mozilla.org/show_bug.cgi?id=1577452 there are some tests that are skipped because they changed cache behaviour, need to reenable them with modernconfig

Points: --- → 5
Priority: -- → P2
Assignee: nobody → standard8
Iteration: --- → 72.2 - Nov 4 - 17

The test as originally written, relied on the fact that the search service would install only the engines listed in the engines array within the cache, and nothing else.

The test was later semi-broken, as it wasn't starting the add-on manager which meant the built-in engines weren't being handled.

Finally, we made changes recently to ensure that the built-in engines are installed if they aren't listed in the cache. This test didn't fail as a result of those changes due to being broken where we'd missed starting the add-on manager.

The changes here make it use the shorter 2-engine list of engines, and include those in the cache reading/writing. This makes it work as expected.

Depends on D53185

This makes visibleDefaultEngines in the cache redundant, and replaces it with a new builtInEngineList that is indexed via the id and locale of the WebExtension. This gives a better indexing method that just display name.

Also bump the cache version to 2, so that we can do safe downgrades/upgrades with pref flips that might not happen at the time of an upgrade.

Depends on D53188

Iteration: 72.2 - Nov 4 - 17 → 72.3 - Nov 18 - Dec 1
Pushed by mbanner@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/9c3e3897366f
Update test_json_cache.js to use modern async/await methods. r=mikedeboer
https://hg.mozilla.org/integration/autoland/rev/af4f34d0ca4a
Fix test_json_cache.js to be testing the cache properly. r=mikedeboer
https://hg.mozilla.org/integration/autoland/rev/39e39bb24898
Move the DEFAULT_TAG constant from SearchService to SearchUtils. r=mikedeboer
https://hg.mozilla.org/integration/autoland/rev/5c271dd2d41a
Get the Search cache working properly with the modern configuration. r=mikedeboer
You need to log in before you can comment on or make changes to this bug.