From 176f8137f9b1d89f5c389211f6cadcbbfeb5e0ad Mon Sep 17 00:00:00 2001 From: Andreas Tolfsen Date: Fri, 4 Mar 2016 18:03:28 +0000 Subject: [PATCH] Bug 1245064 - Lint GeckoDriver#setSessionCapabilities; r=automatedtester MozReview-Commit-ID: GXLGqjKCfVA --HG-- extra : rebase_source : 8a58e5df7e1bf097b26597d6632bab6742a26bc2 --- testing/marionette/driver.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/testing/marionette/driver.js b/testing/marionette/driver.js index a0afdb2a1e40..65e8c95637f0 100644 --- a/testing/marionette/driver.js +++ b/testing/marionette/driver.js @@ -622,6 +622,7 @@ GeckoDriver.prototype.setSessionCapabilities = function(newCaps) { case "desiredCapabilities": to = copy(from[key], to); break; + case "requiredCapabilities": if (from[key].proxy) { this.setUpProxy(from[key].proxy); @@ -631,16 +632,17 @@ GeckoDriver.prototype.setSessionCapabilities = function(newCaps) { for (let caps in from[key]) { if (from[key][caps] !== this.sessionCapabilities[caps]) { errors.push(from[key][caps] + " does not equal " + - this.sessionCapabilities[caps]) ; + this.sessionCapabilities[caps]); } } break; + default: to[key] = from[key]; } } - if (Object.keys(errors).length === 0) { + if (Object.keys(errors).length == 0) { return to; }