Bug 931216 - Convert deprecated octal literals in app update xpcshell tests. r=bbondy
authorRobert Strong <robert.bugzilla@gmail.com>
Sat, 26 Oct 2013 13:36:11 -0700
changeset 166174 33f2f1637653257b041379ab75fb05469c37e52b
parent 166148 6baab9dc96df2407dbff5ede6e1d03cc64d0362a
child 166175 583e0e090fc7b209d10eeafa361b163cf4f12d38
push id3066
push userakeybl@mozilla.com
push dateMon, 09 Dec 2013 19:58:46 +0000
treeherdermozilla-beta@a31a0dce83aa [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbbondy
bugs931216
milestone27.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 931216 - Convert deprecated octal literals in app update xpcshell tests. r=bbondy
toolkit/mozapps/update/tests/unit_aus_update/canCheckForAndCanApplyUpdates.js
toolkit/mozapps/update/tests/unit_aus_update/head_update.js
toolkit/mozapps/update/tests/unit_base_updater/marAppInUseStageSuccessComplete_unix.js
toolkit/mozapps/update/tests/unit_base_updater/marAppInUseSuccessComplete.js
toolkit/mozapps/update/tests/unit_base_updater/marFailurePartial.js
toolkit/mozapps/update/tests/unit_base_updater/marRMRFDirFileInUseFallbackStageFailurePartial_win.js
toolkit/mozapps/update/tests/unit_base_updater/marRMRFDirFileInUseStageSuccessPartial_win.js
toolkit/mozapps/update/tests/unit_base_updater/marRMRFDirFileInUseSuccessPartial_win.js
toolkit/mozapps/update/tests/unit_base_updater/marStageFailurePartial.js
toolkit/mozapps/update/tests/unit_base_updater/marStageSuccessComplete.js
toolkit/mozapps/update/tests/unit_base_updater/marStageSuccessPartial.js
toolkit/mozapps/update/tests/unit_base_updater/marSuccessComplete.js
toolkit/mozapps/update/tests/unit_base_updater/marSuccessPartial.js
toolkit/mozapps/update/tests/unit_service_updater/marAppInUseSuccessCompleteSvc.js
toolkit/mozapps/update/tests/unit_service_updater/marFailurePartialSvc.js
toolkit/mozapps/update/tests/unit_service_updater/marRMRFDirFileInUseFallbackStageFailurePartialSvc_win.js
toolkit/mozapps/update/tests/unit_service_updater/marRMRFDirFileInUseStageSuccessPartialSvc_win.js
toolkit/mozapps/update/tests/unit_service_updater/marRMRFDirFileInUseSuccessPartialSvc_win.js
toolkit/mozapps/update/tests/unit_service_updater/marStageFailurePartialSvc.js
toolkit/mozapps/update/tests/unit_service_updater/marStageSuccessCompleteSvc.js
toolkit/mozapps/update/tests/unit_service_updater/marStageSuccessPartialSvc.js
toolkit/mozapps/update/tests/unit_service_updater/marSuccessCompleteSvc.js
toolkit/mozapps/update/tests/unit_service_updater/marSuccessPartialSvc.js
--- a/toolkit/mozapps/update/tests/unit_aus_update/canCheckForAndCanApplyUpdates.js
+++ b/toolkit/mozapps/update/tests/unit_aus_update/canCheckForAndCanApplyUpdates.js
@@ -5,17 +5,17 @@
 
 function run_test() {
   setupTestCommon(true);
 
   // Verify write access to the custom app dir
   logTestInfo("testing write access to the application directory");
   var testFile = getCurrentProcessDir();
   testFile.append("update_write_access_test");
-  testFile.create(AUS_Ci.nsIFile.NORMAL_FILE_TYPE, 0644);
+  testFile.create(AUS_Ci.nsIFile.NORMAL_FILE_TYPE, 0o644);
   do_check_true(testFile.exists());
   testFile.remove(false);
   do_check_false(testFile.exists());
 
   standardInit();
 
   // Check if available updates can be checked for
   logTestInfo("testing nsIApplicationUpdateService:canCheckForUpdates");
--- a/toolkit/mozapps/update/tests/unit_aus_update/head_update.js
+++ b/toolkit/mozapps/update/tests/unit_aus_update/head_update.js
@@ -2200,33 +2200,33 @@ function symlinkUpdateFilesIntoBundleDir
                              ctypes.char.ptr, ctypes.char.ptr);
   let unlink = libc.declare("unlink", ctypes.default_abi, ctypes.int,
                             ctypes.char.ptr);
 
   // Symlink active-update.xml
   let dest = getAppDir();
   dest.append("active-update.xml");
   if (!dest.exists()) {
-    dest.create(dest.NORMAL_FILE_TYPE, 6 * 64 + 4 * 8 + 4); // 0644
+    dest.create(dest.NORMAL_FILE_TYPE, 0o644);
   }
   do_check_true(dest.exists());
   let source = getUpdatesRootDir();
   source.append("active-update.xml");
   unlink(source.path);
   let ret = symlink(dest.path, source.path);
   do_check_eq(ret, 0);
   do_check_true(source.exists());
 
   // Symlink updates/
   let dest2 = getAppDir();
   dest2.append("updates");
   if (dest2.exists()) {
     dest2.remove(true);
   }
-  dest2.create(dest.DIRECTORY_TYPE, 7 * 64 + 5 * 8 + 5); // 0755
+  dest2.create(dest.DIRECTORY_TYPE, 0o755);
   do_check_true(dest2.exists());
   let source2 = getUpdatesRootDir();
   source2.append("updates");
   if (source2.exists()) {
     source2.remove(true);
   }
   ret = symlink(dest2.path, source2.path);
   do_check_eq(ret, 0);
@@ -2254,17 +2254,17 @@ function symlinkUpdateFilesIntoBundleDir
  * files.
  */
 function adjustPathsOnWindows() {
   logTestInfo("start - setup new process directory");
   // We copy the entire GRE directory into another location so that xpcshell
   // running doesn't prevent the updater from moving stuff around.
   let tmpDir = do_get_profile();
   tmpDir.append("ExecutableDir.tmp");
-  tmpDir.createUnique(tmpDir.DIRECTORY_TYPE, 7 * 64 + 5 * 8 + 5); // 0755
+  tmpDir.createUnique(tmpDir.DIRECTORY_TYPE, 0o755);
   let procDir = getCurrentProcessDir();
   logTestInfo("start - copy the process directory");
   copyMinimumAppFiles(procDir, tmpDir, "bin");
   logTestInfo("finish - copy the process directory");
   let newDir = tmpDir.clone();
   newDir.append("bin");
   gWindowsBinDir = newDir;
   logTestInfo("Using this new bin directory: " + gWindowsBinDir.path);
--- a/toolkit/mozapps/update/tests/unit_base_updater/marAppInUseStageSuccessComplete_unix.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marAppInUseStageSuccessComplete_unix.js
@@ -11,194 +11,194 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0767
+  originalPerms    : 0o767,
+  comparePerms     : 0o767
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "removed-files",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_removed-files",
   compareFile      : "complete_removed-files",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0644
+  originalPerms    : 0o767,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0677,
-  comparePerms     : 0644
+  originalPerms    : 0o677,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
-  originalPerms    : 0776,
-  comparePerms     : 0644
+  originalPerms    : 0o776,
+  comparePerms     : 0o644
 }, {
   description      : "Removed by precomplete (remove)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
--- a/toolkit/mozapps/update/tests/unit_base_updater/marAppInUseSuccessComplete.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marAppInUseSuccessComplete.js
@@ -11,194 +11,194 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0767
+  originalPerms    : 0o767,
+  comparePerms     : 0o767
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "removed-files",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_removed-files",
   compareFile      : "complete_removed-files",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0644
+  originalPerms    : 0o767,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0677,
-  comparePerms     : 0644
+  originalPerms    : 0o677,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
-  originalPerms    : 0776,
-  comparePerms     : 0644
+  originalPerms    : 0o776,
+  comparePerms     : 0o644
 }, {
   description      : "Removed by precomplete (remove)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
--- a/toolkit/mozapps/update/tests/unit_base_updater/marFailurePartial.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marFailurePartial.js
@@ -12,58 +12,58 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
+  originalPerms    : 0o767,
   comparePerms     : null
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0775
+  originalPerms    : 0o775,
+  comparePerms     : 0o775
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
@@ -72,79 +72,79 @@ const TEST_FILES = [
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Not patched for failed update (patch) and causes " +
                      "LoadSourceFile failed",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
@@ -153,18 +153,18 @@ const TEST_FILES = [
 }, {
   description      : "Not patched for failed update (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
@@ -193,28 +193,28 @@ const TEST_FILES = [
 }, {
   description      : "Not removed for failed update (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ShouldNotBeDeleted\n",
   compareContents  : "ShouldNotBeDeleted\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not removed for failed update (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ShouldNotBeDeleted\n",
   compareContents  : "ShouldNotBeDeleted\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Not removed for failed update (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : false
 }, {
--- a/toolkit/mozapps/update/tests/unit_base_updater/marRMRFDirFileInUseFallbackStageFailurePartial_win.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marRMRFDirFileInUseFallbackStageFailurePartial_win.js
@@ -10,217 +10,177 @@
 const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
-  compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete_precomplete"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0775
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : "ToBeDeleted\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeDeleted\n",
   compareContents  : "ToBeDeleted\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Removed by update.manifest (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : true
 }, {
--- a/toolkit/mozapps/update/tests/unit_base_updater/marRMRFDirFileInUseStageSuccessPartial_win.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marRMRFDirFileInUseStageSuccessPartial_win.js
@@ -10,217 +10,177 @@
 const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
-  compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete_precomplete"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0775
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : "ToBeDeleted\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeDeleted\n",
   compareContents  : "ToBeDeleted\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Removed by update.manifest (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : true
 }, {
--- a/toolkit/mozapps/update/tests/unit_base_updater/marRMRFDirFileInUseSuccessPartial_win.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marRMRFDirFileInUseSuccessPartial_win.js
@@ -10,217 +10,177 @@
 const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
-  compareFile      : "partial_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  compareFile      : "partial_precomplete"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : null
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : null
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : "partial.png",
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Removed by update.manifest (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : true
 }, {
--- a/toolkit/mozapps/update/tests/unit_base_updater/marStageFailurePartial.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marStageFailurePartial.js
@@ -12,58 +12,58 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
+  originalPerms    : 0o767,
   comparePerms     : null
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0775
+  originalPerms    : 0o775,
+  comparePerms     : 0o775
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
@@ -72,79 +72,79 @@ const TEST_FILES = [
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Not patched for failed update (patch) and causes " +
                      "LoadSourceFile failed",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
@@ -153,18 +153,18 @@ const TEST_FILES = [
 }, {
   description      : "Not patched for failed update (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
@@ -193,28 +193,28 @@ const TEST_FILES = [
 }, {
   description      : "Not removed for failed update (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ShouldNotBeDeleted\n",
   compareContents  : "ShouldNotBeDeleted\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not removed for failed update (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ShouldNotBeDeleted\n",
   compareContents  : "ShouldNotBeDeleted\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Not removed for failed update (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : false
 }, {
--- a/toolkit/mozapps/update/tests/unit_base_updater/marStageSuccessComplete.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marStageSuccessComplete.js
@@ -12,194 +12,194 @@ var TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 7 * 64 + 6 * 8 + 7, // 0767
-  comparePerms     : 7 * 64 + 6 * 8 + 7 // 0767
+  originalPerms    : 0o767,
+  comparePerms     : 0o767
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 6 * 64 + 6 * 8 + 6, // 0666
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 7 * 64 + 7 * 8 + 5, // 0775
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 6 * 64 + 6 * 8 + 6, // 0666
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "removed-files",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_removed-files",
   compareFile      : "complete_removed-files",
-  originalPerms    : 6 * 64 + 6 * 8 + 6, // 0666
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 6 * 64 + 6 * 8 + 6, // 0666
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 7 * 64 + 7 * 8 + 7, // 0777
-  comparePerms     : 7 * 64 + 5 * 8 + 5 // 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 7 * 64 + 6 * 8 + 7, // 0767
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  originalPerms    : 0o767,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 7 * 64 + 7 * 8 + 7, // 0777
-  comparePerms     : 7 * 64 + 5 * 8 + 5 // 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 6 * 64 + 7 * 8 + 7, // 0677
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  originalPerms    : 0o677,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 7 * 64 + 7 * 8 + 5, // 0775
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
-  originalPerms    : 7 * 64 + 7 * 8 + 6, // 0776
-  comparePerms     : 6 * 64 + 4 * 8 + 4 // 0644
+  originalPerms    : 0o776,
+  comparePerms     : 0o644
 }, {
   description      : "Removed by precomplete (remove)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
@@ -286,18 +286,18 @@ function run_test() {
     TEST_FILES.push({
       description      : "Readable symlink",
       fileName         : "link",
       relPathDir       : "a/b/",
       originalContents : "test",
       compareContents  : "test",
       originalFile     : null,
       compareFile      : null,
-      originalPerms    : 6 * 64 + 6 * 8 + 4, // 0664
-      comparePerms     : 6 * 64 + 6 * 8 + 4 // 0664
+      originalPerms    : 0o664,
+      comparePerms     : 0o664
     });
   }
 
   // apply the complete mar
   let exitValue = runUpdate();
   logTestInfo("testing updater binary process exitValue for success when " +
               "applying a complete mar");
   let updateLog = do_get_file(gTestID + UPDATES_DIR_SUFFIX, true);
--- a/toolkit/mozapps/update/tests/unit_base_updater/marStageSuccessPartial.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marStageSuccessPartial.js
@@ -12,196 +12,196 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
+  originalPerms    : 0o644,
   comparePerms     : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
   compareFile      : "partial_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "partial.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
--- a/toolkit/mozapps/update/tests/unit_base_updater/marSuccessComplete.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marSuccessComplete.js
@@ -12,194 +12,194 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0767
+  originalPerms    : 0o767,
+  comparePerms     : 0o767
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "removed-files",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_removed-files",
   compareFile      : "complete_removed-files",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0644
+  originalPerms    : 0o767,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0677,
-  comparePerms     : 0644
+  originalPerms    : 0o677,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
-  originalPerms    : 0776,
-  comparePerms     : 0644
+  originalPerms    : 0o776,
+  comparePerms     : 0o644
 }, {
   description      : "Removed by precomplete (remove)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
--- a/toolkit/mozapps/update/tests/unit_base_updater/marSuccessPartial.js
+++ b/toolkit/mozapps/update/tests/unit_base_updater/marSuccessPartial.js
@@ -12,196 +12,196 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
+  originalPerms    : 0o644,
   comparePerms     : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
   compareFile      : "partial_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "partial.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
--- a/toolkit/mozapps/update/tests/unit_service_updater/marAppInUseSuccessCompleteSvc.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marAppInUseSuccessCompleteSvc.js
@@ -11,194 +11,194 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0767
+  originalPerms    : 0o767,
+  comparePerms     : 0o767
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "removed-files",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_removed-files",
   compareFile      : "complete_removed-files",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0644
+  originalPerms    : 0o767,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0677,
-  comparePerms     : 0644
+  originalPerms    : 0o677,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
-  originalPerms    : 0776,
-  comparePerms     : 0644
+  originalPerms    : 0o776,
+  comparePerms     : 0o644
 }, {
   description      : "Removed by precomplete (remove)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
--- a/toolkit/mozapps/update/tests/unit_service_updater/marFailurePartialSvc.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marFailurePartialSvc.js
@@ -12,58 +12,58 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
+  originalPerms    : 0o767,
   comparePerms     : null
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0775
+  originalPerms    : 0o775,
+  comparePerms     : 0o775
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
@@ -72,79 +72,79 @@ const TEST_FILES = [
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Not patched for failed update (patch) and causes " +
                      "LoadSourceFile failed",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
@@ -153,18 +153,18 @@ const TEST_FILES = [
 }, {
   description      : "Not patched for failed update (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
@@ -193,28 +193,28 @@ const TEST_FILES = [
 }, {
   description      : "Not removed for failed update (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ShouldNotBeDeleted\n",
   compareContents  : "ShouldNotBeDeleted\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not removed for failed update (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ShouldNotBeDeleted\n",
   compareContents  : "ShouldNotBeDeleted\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Not removed for failed update (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : false
 }, {
--- a/toolkit/mozapps/update/tests/unit_service_updater/marRMRFDirFileInUseFallbackStageFailurePartialSvc_win.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marRMRFDirFileInUseFallbackStageFailurePartialSvc_win.js
@@ -10,217 +10,177 @@
 const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
-  compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete_precomplete"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0775
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : "ToBeDeleted\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeDeleted\n",
   compareContents  : "ToBeDeleted\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Removed by update.manifest (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : true
 }, {
--- a/toolkit/mozapps/update/tests/unit_service_updater/marRMRFDirFileInUseStageSuccessPartialSvc_win.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marRMRFDirFileInUseStageSuccessPartialSvc_win.js
@@ -10,217 +10,177 @@
 const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
-  compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete_precomplete"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0775
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  compareFile      : "complete.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "ToBeReplacedWithFromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "complete.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : "ToBeDeleted\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeDeleted\n",
   compareContents  : "ToBeDeleted\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Removed by update.manifest (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : true
 }, {
--- a/toolkit/mozapps/update/tests/unit_service_updater/marRMRFDirFileInUseSuccessPartialSvc_win.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marRMRFDirFileInUseSuccessPartialSvc_win.js
@@ -10,217 +10,177 @@
 const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
-  compareFile      : "partial_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  compareFile      : "partial_precomplete"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : null
+  compareFile      : "partial.png"
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : null
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
-  compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
-  compareFile      : "partial.png",
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : "partial.png"
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : 0644
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
-  compareFile      : null,
-  originalPerms    : null,
-  comparePerms     : null
+  compareFile      : null
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Removed by update.manifest (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : true
 }, {
--- a/toolkit/mozapps/update/tests/unit_service_updater/marStageFailurePartialSvc.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marStageFailurePartialSvc.js
@@ -12,58 +12,58 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
+  originalPerms    : 0o767,
   comparePerms     : null
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0775
+  originalPerms    : 0o775,
+  comparePerms     : 0o775
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
@@ -72,79 +72,79 @@ const TEST_FILES = [
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Not patched for failed update (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Not patched for failed update (patch) and causes " +
                      "LoadSourceFile failed",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
@@ -153,18 +153,18 @@ const TEST_FILES = [
 }, {
   description      : "Not patched for failed update (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not added for failed update (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
@@ -193,28 +193,28 @@ const TEST_FILES = [
 }, {
   description      : "Not removed for failed update (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ShouldNotBeDeleted\n",
   compareContents  : "ShouldNotBeDeleted\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Not removed for failed update (remove)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ShouldNotBeDeleted\n",
   compareContents  : "ShouldNotBeDeleted\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }];
 
 ADDITIONAL_TEST_DIRS = [
 {
   description  : "Not removed for failed update (rmdir)",
   relPathDir   : "a/b/1/10/",
   dirRemoved   : false
 }, {
--- a/toolkit/mozapps/update/tests/unit_service_updater/marStageSuccessCompleteSvc.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marStageSuccessCompleteSvc.js
@@ -12,194 +12,194 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0767
+  originalPerms    : 0o767,
+  comparePerms     : 0o767
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "removed-files",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_removed-files",
   compareFile      : "complete_removed-files",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0644
+  originalPerms    : 0o767,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0677,
-  comparePerms     : 0644
+  originalPerms    : 0o677,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
-  originalPerms    : 0776,
-  comparePerms     : 0644
+  originalPerms    : 0o776,
+  comparePerms     : 0o644
 }, {
   description      : "Removed by precomplete (remove)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
--- a/toolkit/mozapps/update/tests/unit_service_updater/marStageSuccessPartialSvc.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marStageSuccessPartialSvc.js
@@ -12,196 +12,196 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
+  originalPerms    : 0o644,
   comparePerms     : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
   compareFile      : "partial_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "partial.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
--- a/toolkit/mozapps/update/tests/unit_service_updater/marSuccessCompleteSvc.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marSuccessCompleteSvc.js
@@ -12,194 +12,194 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0767
+  originalPerms    : 0o767,
+  comparePerms     : 0o767
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_precomplete",
   compareFile      : "complete_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "removed-files",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial_removed-files",
   compareFile      : "complete_removed-files",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0767,
-  comparePerms     : 0644
+  originalPerms    : 0o767,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "partial.png",
   compareFile      : "complete.png",
-  originalPerms    : 0777,
-  comparePerms     : 0755
+  originalPerms    : 0o777,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text1",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0677,
-  comparePerms     : 0644
+  originalPerms    : 0o677,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromComplete\n",
   compareContents  : "FromComplete\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "complete.png",
-  originalPerms    : 0776,
-  comparePerms     : 0644
+  originalPerms    : 0o776,
+  comparePerms     : 0o644
 }, {
   description      : "Removed by precomplete (remove)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,
--- a/toolkit/mozapps/update/tests/unit_service_updater/marSuccessPartialSvc.js
+++ b/toolkit/mozapps/update/tests/unit_service_updater/marSuccessPartialSvc.js
@@ -12,196 +12,196 @@ const TEST_FILES = [
 {
   description      : "Should never change",
   fileName         : "channel-prefs.js",
   relPathDir       : "a/b/defaults/pref/",
   originalContents : "ShouldNotBeReplaced\n",
   compareContents  : "ShouldNotBeReplaced\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
+  originalPerms    : 0o644,
   comparePerms     : null
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "precomplete",
   relPathDir       : "",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete_precomplete",
   compareFile      : "partial_precomplete",
-  originalPerms    : 0666,
-  comparePerms     : 0644
+  originalPerms    : 0o666,
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "searchpluginstext0",
   relPathDir       : "a/b/searchplugins/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0775,
-  comparePerms     : 0644
+  originalPerms    : 0o775,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng1.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Patched by update.manifest if the file exists " +
                      "(patch-if)",
   fileName         : "searchpluginspng0.png",
   relPathDir       : "a/b/searchplugins/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions1text0",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png1.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions1png0.png",
   relPathDir       : "a/b/extensions/extensions1/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest if the parent directory " +
                      "exists (add-if)",
   fileName         : "extensions0text0",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png1.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest if the parent directory " +
                      "exists (patch-if)",
   fileName         : "extensions0png0.png",
   relPathDir       : "a/b/extensions/extensions0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "exe0.exe",
   relPathDir       : "a/b/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "0exe0.exe",
   relPathDir       : "a/b/0/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0755,
-  comparePerms     : 0755
+  originalPerms    : 0o755,
+  comparePerms     : 0o755
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text0",
   relPathDir       : "a/b/0/00/",
   originalContents : "ToBeReplacedWithFromPartial\n",
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
-  originalPerms    : 0644,
-  comparePerms     : 0644
+  originalPerms    : 0o644,
+  comparePerms     : 0o644
 }, {
   description      : "Patched by update.manifest (patch)",
   fileName         : "00png0.png",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : null,
   originalFile     : "complete.png",
   compareFile      : "partial.png",
-  originalPerms    : 0666,
-  comparePerms     : 0666
+  originalPerms    : 0o666,
+  comparePerms     : 0o666
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20text0",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "20png0.png",
   relPathDir       : "a/b/2/20/",
   originalContents : null,
   compareContents  : null,
   originalFile     : null,
   compareFile      : "partial.png",
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Added by update.manifest (add)",
   fileName         : "00text2",
   relPathDir       : "a/b/0/00/",
   originalContents : null,
   compareContents  : "FromPartial\n",
   originalFile     : null,
   compareFile      : null,
   originalPerms    : null,
-  comparePerms     : 0644
+  comparePerms     : 0o644
 }, {
   description      : "Removed by update.manifest (remove)",
   fileName         : "10text0",
   relPathDir       : "a/b/1/10/",
   originalContents : "ToBeDeleted\n",
   compareContents  : null,
   originalFile     : null,
   compareFile      : null,