[meta] Convert consumers of UpdatePlaces to PlacesUtils.history.insert(Many) or PlacesTestUtils.addVisits

RESOLVED FIXED in mozilla61

Status

()

enhancement
P5
normal
RESOLVED FIXED
a year ago
a year ago

People

(Reporter: standard8, Unassigned)

Tracking

unspecified
mozilla61
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [fxsearch])

(Reporter)

Description

a year ago
+++ This bug was initially created as a clone of Bug #1282770 +++

updatePlaces doesn't have a great API for javascript, thus I'd like to convert its consumers to the new PlacesUtils.history.insert(Many) APIs.
alternatively, tests code can use PlacesTestUtils.addVisits, that has an ever more streamlined API.

These are the code points
http://searchfox.org/mozilla-central/search?q=.updatePlaces%28&path=

Though, the following files should not be changed:
toolkit/components/places/History.jsm (implementation)
toolkit/components/places/tests/PlacesTestUtils.jsm (covered by bug 1272686)
toolkit/components/places/tests/unit/test_async_history_api.js (own test)

Would also be great to remove the addVisits helper from toolkit/components/places/tests/browser/head.js and replace its usage in those tests with PlacesTestUtils.addVisits
(Reporter)

Comment 1

a year ago
Note: this is a meta bug, I'll be adding the remaining work in bugs this will depend on.
Mentor: mak77
likely also test_updatePlaces_embed.js could stay as is
(Reporter)

Updated

a year ago
Depends on: 1448057
(Reporter)

Updated

a year ago
Depends on: 1448064
(Reporter)

Updated

a year ago
Depends on: 1448081
This is mostly done, there are a few entries left but we can handle those in bug 1354531
Status: NEW → RESOLVED
Last Resolved: a year ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla61
You need to log in before you can comment on or make changes to this bug.