Closed
Bug 538765
Opened 15 years ago
Closed 14 years ago
cleanup Places browserGlue tests
Categories
(Firefox :: Bookmarks & History, defect)
Firefox
Bookmarks & History
Tracking
()
RESOLVED
FIXED
Firefox 3.7a1
People
(Reporter: mak, Assigned: mak)
Details
Attachments
(1 file)
23.06 KB,
patch
|
dietrich
:
review+
|
Details | Diff | Splinter Review |
for better usage of notifications. i'm already cleaning up _smartBookmarks and _prefs since they are randomly failing and i hope to make them consistent. This handles the other tests, that are working but could be better.
Attachment #420887 -
Flags: review?(dietrich)
Comment 1•15 years ago
|
||
Comment on attachment 420887 [details] [diff] [review] patch v1.0 >diff --git a/browser/components/places/tests/unit/test_browserGlue_migrate.js b/browser/components/places/tests/unit/test_browserGlue_migrate.js >--- a/browser/components/places/tests/unit/test_browserGlue_migrate.js >+++ b/browser/components/places/tests/unit/test_browserGlue_migrate.js >@@ -79,13 +77,8 @@ function run_test() { > bs.DEFAULT_INDEX, "migrated"); > > // Initialize nsBrowserGlue. >- Cc["@mozilla.org/browser/browserglue;1"].getService(Ci.nsIBrowserGlue); >- >- // Places initialization has already happened, so we need to simulate >- // it. This will force browserGlue::_initPlaces(). >- let os = Cc["@mozilla.org/observer-service;1"]. >- getService(Ci.nsIObserverService); >- os.notifyObservers(null, TOPIC_PLACES_INIT_COMPLETE, null); >+ let bg = Cc["@mozilla.org/browser/browserglue;1"]. >+ getService(Ci.nsIBrowserGlue); why don't you need to send the notification here anymore?
Assignee | ||
Comment 2•15 years ago
|
||
because initing any Places service enqueues the notification, when we later call do_timeout the enqueued notification will be served, so no reason to force it.
Updated•15 years ago
|
Attachment #420887 -
Flags: review?(dietrich) → review+
Assignee | ||
Comment 3•14 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/6c1fb8fedeae
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 3.7a1
You need to log in
before you can comment on or make changes to this bug.
Description
•