1
Index: firefox-trunk-19.0~a1~hg20121114r113129/docshell/test/unit/head_docshell.js
2
===================================================================
3
--- firefox-trunk-19.0~a1~hg20121114r113129.orig/docshell/test/unit/head_docshell.js 2012-11-14 00:37:36.000000000 +0000
4
+++ firefox-trunk-19.0~a1~hg20121114r113129/docshell/test/unit/head_docshell.js 2012-11-14 14:59:33.306495000 +0000
6
const Ci = Components.interfaces;
7
const Cr = Components.results;
9
-var dirSvc = Cc["@mozilla.org/file/directory_service;1"].
10
- getService(Ci.nsIProperties);
11
-var profileDir = dirSvc.get("CurProcD", Ci.nsILocalFile);
12
-profileDir.append("test_docshell_profile");
14
-// Register our own provider for the profile directory.
15
-// It will return our special docshell profile directory.
17
- getFile: function(prop, persistent) {
18
- persistent.value = true;
19
- if (prop == "ProfD") {
20
- var retVal = dirSvc.get("CurProcD", Ci.nsILocalFile);
21
- retVal.append("test_docshell_profile");
22
- if (!retVal.exists())
23
- retVal.create(Ci.nsIFile.DIRECTORY_TYPE, 0755);
26
- throw Cr.NS_ERROR_FAILURE;
28
- QueryInterface: function(iid) {
29
- if (iid.equals(Ci.nsIDirectoryServiceProvider) ||
30
- iid.equals(Ci.nsISupports)) {
33
- throw Cr.NS_ERROR_NO_INTERFACE;
36
-dirSvc.QueryInterface(Ci.nsIDirectoryService).registerProvider(provider);
40
- // we need to remove the folder that we created for the profile
42
- if (profileDir.exists())
43
- profileDir.remove(true);
45
- // windows has a slight problem with sqlite databases and trying to remove
46
- // them to quickly after you might expect to be done with them. Eat any
47
- // errors we'll get. This should be OK because we cleanup before and after
53
-// cleanup from any failed test runs in the past
56
-// make sure we have our profile directory available to us
57
-profileDir.create(Ci.nsIFile.DIRECTORY_TYPE, 0755);
58
+// Needed to properly setup and shutdown the profile.
60
Index: firefox-trunk-19.0~a1~hg20121114r113129/docshell/test/unit/test_nsIDownloadHistory.js
61
===================================================================
62
--- firefox-trunk-19.0~a1~hg20121114r113129.orig/docshell/test/unit/test_nsIDownloadHistory.js 2012-11-14 00:37:36.000000000 +0000
63
+++ firefox-trunk-19.0~a1~hg20121114r113129/docshell/test/unit/test_nsIDownloadHistory.js 2012-11-14 14:59:26.738495000 +0000
68
- // Needed to properly setup and shutdown the profile.
71
Services.prefs.setBoolPref("places.history.enabled", true);
73
for (var i = 0; i < tests.length; i++)