Bug 1447903: Part 11b - Update test_strictcompatibility.js to use bootstrapped extensions. r?aswan draft
authorKris Maglione <maglione.k@gmail.com>
Wed, 21 Mar 2018 21:10:20 -0700
changeset 772381 beef6cd41136c5a8900e3ec8046899bfbb116b09
parent 772380 d8bb790054e55d2d73172d7de7839bc63144432b
child 772382 07a4c48cadea3d58224f7bace72d1668779d3d31
push id103897
push usermaglione.k@gmail.com
push dateMon, 26 Mar 2018 01:31:53 +0000
reviewersaswan
bugs1447903
milestone61.0a1
Bug 1447903: Part 11b - Update test_strictcompatibility.js to use bootstrapped extensions. r?aswan MozReview-Commit-ID: 4DES7jiBzmF
toolkit/mozapps/extensions/test/xpcshell/head_addons.js
toolkit/mozapps/extensions/test/xpcshell/test_strictcompatibility.js
--- a/toolkit/mozapps/extensions/test/xpcshell/head_addons.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/head_addons.js
@@ -77,17 +77,16 @@ const LEGACY_NON_RESTARTLESS_TESTS = new
   "test_bug455906.js",
   "test_bug470377_1.js",
   "test_bug470377_2.js",
   "test_bug470377_3.js",
   "test_bug470377_4.js",
   "test_bug655254.js",
   "test_checkcompatibility.js",
   "test_signed_verify.js",
-  "test_strictcompatibility.js",
   "test_syncGUID.js",
   "test_upgrade.js",
 ]);
 
 if (LEGACY_NON_RESTARTLESS_TESTS.has(_TEST_FILE[0].replace(/.*\//, ""))) {
   Services.prefs.setBoolPref("extensions.legacy.non-restartless.enabled", true);
 }
 
--- a/toolkit/mozapps/extensions/test/xpcshell/test_strictcompatibility.js
+++ b/toolkit/mozapps/extensions/test/xpcshell/test_strictcompatibility.js
@@ -10,16 +10,17 @@
 // should be compatible in. It's pretty gross.
 const ADDONS = {
   // Always compatible
   "addon1@tests.mozilla.org": {
     "install.rdf": {
       id: "addon1@tests.mozilla.org",
       version: "1.0",
       name: "Test 1",
+      bootstrap: true,
       targetApplications: [{
         id: "xpcshell@tests.mozilla.org",
         minVersion: "1",
         maxVersion: "1"
       }]
     },
     expected: {
       strictCompatibility: false,
@@ -28,16 +29,17 @@ const ADDONS = {
   },
 
   // Incompatible in strict compatibility mode
   "addon2@tests.mozilla.org": {
     "install.rdf": {
       id: "addon2@tests.mozilla.org",
       version: "1.0",
       name: "Test 2",
+      bootstrap: true,
       targetApplications: [{
         id: "xpcshell@tests.mozilla.org",
         minVersion: "0.7",
         maxVersion: "0.8"
       }]
     },
     expected: {
       strictCompatibility: false,
@@ -65,16 +67,17 @@ const ADDONS = {
   },
 
   // Opt-in to strict compatibility - always incompatible
   "addon4@tests.mozilla.org": {
     "install.rdf": {
       id: "addon4@tests.mozilla.org",
       version: "1.0",
       name: "Test 4",
+      bootstrap: true,
       strictCompatibility: true,
       targetApplications: [{
         id: "xpcshell@tests.mozilla.org",
         minVersion: "0.8",
         maxVersion: "0.9"
       }]
     },
     expected: {
@@ -85,16 +88,17 @@ const ADDONS = {
 
   // Addon from the future - would be marked as compatibile-by-default,
   // but minVersion is higher than the app version
   "addon5@tests.mozilla.org": {
     "install.rdf": {
       id: "addon5@tests.mozilla.org",
       version: "1.0",
       name: "Test 5",
+      bootstrap: true,
       targetApplications: [{
         id: "xpcshell@tests.mozilla.org",
         minVersion: "3",
         maxVersion: "5"
       }]
     },
     expected: {
       strictCompatibility: false,
@@ -104,16 +108,17 @@ const ADDONS = {
 
   // Extremely old addon - maxVersion is less than the mimimum compat version
   // set in extensions.minCompatibleVersion
   "addon6@tests.mozilla.org": {
     "install.rdf": {
       id: "addon6@tests.mozilla.org",
       version: "1.0",
       name: "Test 6",
+      bootstrap: true,
       targetApplications: [{
         id: "xpcshell@tests.mozilla.org",
         minVersion: "0.1",
         maxVersion: "0.2"
       }]
     },
     expected: {
       strictCompatibility: false,