Bug 713293 - Send quit-application in toolkit/components/downloads/test/schema_migration/head_migration.js. r=mak.
authorRafael Ávila de Espíndola <respindola@mozilla.com>
Thu, 29 Dec 2011 10:08:03 -0500
changeset 84739 cff462dee8f7b7ddd372593567e8d17005c667f9
parent 84738 3d2067f2a7f1e04d4a8179a28c5aa925a257a923
child 84740 ef6d44e6087546920da248d9d369f143082709b0
push id805
push userakeybl@mozilla.com
push dateWed, 01 Feb 2012 18:17:35 +0000
treeherdermozilla-aurora@6fb3bf232436 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmak
bugs713293
milestone12.0a1
Bug 713293 - Send quit-application in toolkit/components/downloads/test/schema_migration/head_migration.js. r=mak.
toolkit/components/downloads/test/schema_migration/head_migration.js
--- a/toolkit/components/downloads/test/schema_migration/head_migration.js
+++ b/toolkit/components/downloads/test/schema_migration/head_migration.js
@@ -29,22 +29,28 @@
  * use your version of this file under the terms of the MPL, indicate your
  * decision by devaring the provisions above and replace them with the notice
  * and other provisions required by the GPL or the LGPL. If you do not devare
  * the provisions above, a recipient may use your version of this file under
  * the terms of any one of the MPL, the GPL or the LGPL.
  *
  * ***** END LICENSE BLOCK ***** */
 
+Components.utils.import("resource://gre/modules/Services.jsm");
+
 const Cc = Components.classes;
 const Ci = Components.interfaces;
 const Cr = Components.results;
 
 do_get_profile();
 
+do_register_cleanup(function() {
+  Services.obs.notifyObservers(null, "quit-application", null);
+});
+
 var dirSvc = Cc["@mozilla.org/file/directory_service;1"].
              getService(Ci.nsIProperties);
 
 function importDatabaseFile(aFName)
 {
   var file = do_get_file(aFName);
   var newFile = dirSvc.get("ProfD", Ci.nsIFile);
   file.copyTo(newFile, "downloads.sqlite");