Bug 1480810 - Drop PREF_COMPLEX from Marionette prefs module. r=automatedtester
authorAndreas Tolfsen <ato@sny.no>
Fri, 03 Aug 2018 16:33:56 +0100
changeset 826852 541bad93631c1dfbb89fd0c7c32fb11662df2d40
parent 826851 027922b5ef0442e4ebb07043d2b57961e6195a78
child 826853 bcd31adc1e7a2bac67c7f9dcce38eb42d1f66c48
push id118394
push usermaglione.k@gmail.com
push dateSun, 05 Aug 2018 20:34:06 +0000
reviewersautomatedtester
bugs1480810
milestone63.0a1
Bug 1480810 - Drop PREF_COMPLEX from Marionette prefs module. r=automatedtester A warning appears in the console when you run xpcshell tests that the PREF_COMPLEX type is no longer, and we should therefore remove it from Marionette as well.
testing/marionette/prefs.js
--- a/testing/marionette/prefs.js
+++ b/testing/marionette/prefs.js
@@ -9,17 +9,16 @@ ChromeUtils.import("resource://gre/modul
 ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyServiceGetter(this, "env",
     "@mozilla.org/process/environment;1",
     "nsIEnvironment");
 
 const {
   PREF_BOOL,
-  PREF_COMPLEX,
   PREF_INT,
   PREF_INVALID,
   PREF_STRING,
 } = Ci.nsIPrefBranch;
 
 this.EXPORTED_SYMBOLS = [
   "Branch",
   "MarionettePrefs",
@@ -56,19 +55,16 @@ class Branch {
         return this._branch.getStringPref(pref);
 
       case PREF_BOOL:
         return this._branch.getBoolPref(pref);
 
       case PREF_INT:
         return this._branch.getIntPref(pref);
 
-      case PREF_COMPLEX:
-        throw new TypeError(`Unsupported complex preference: ${pref}`);
-
       case PREF_INVALID:
       default:
         if (fallback != null) {
           return fallback;
         }
         throw new TypeError(`Unrecognised preference: ${pref}`);
     }
   }