Bug 1103196 - Add insecure certificate error; r=automatedtester
MozReview-Commit-ID: 26wwOuqWhog
--- a/testing/marionette/client/marionette_driver/errors.py
+++ b/testing/marionette/client/marionette_driver/errors.py
@@ -50,16 +50,20 @@ class MarionetteException(Exception):
return msg
class ElementNotSelectableException(MarionetteException):
status = "element not selectable"
+class InsecureCertificateException(MarionetteException):
+ status = "insecure certificate"
+
+
class InvalidArgumentException(MarionetteException):
status = "invalid argument"
class InvalidSessionIdException(MarionetteException):
status = "invalid session id"
--- a/testing/marionette/error.js
+++ b/testing/marionette/error.js
@@ -4,16 +4,17 @@
"use strict";
const {interfaces: Ci, utils: Cu} = Components;
const ERRORS = new Set([
"ElementNotAccessibleError",
"ElementNotVisibleError",
+ "InsecureCertificateError",
"InvalidArgumentError",
"InvalidElementStateError",
"InvalidSelectorError",
"InvalidSessionIdError",
"JavaScriptError",
"NoAlertOpenError",
"NoSuchElementError",
"NoSuchFrameError",
@@ -224,16 +225,23 @@ ElementNotAccessibleError.prototype = Ob
this.ElementNotVisibleError = function(msg) {
WebDriverError.call(this, msg);
this.name = "ElementNotVisibleError";
this.status = "element not visible";
};
ElementNotVisibleError.prototype = Object.create(WebDriverError.prototype);
+this.InsecureCertificateError = function(msg) {
+ WebDriverError.call(this, msg);
+ this.name = "InsecureCertificateError";
+ this.status = "insecure certificate";
+};
+InsecureCertificateError.prototype = Object.create(WebDriverError.prototype);
+
this.InvalidArgumentError = function(msg) {
WebDriverError.call(this, msg);
this.name = "InvalidArgumentError";
this.status = "invalid argument";
};
InvalidArgumentError.prototype = Object.create(WebDriverError.prototype);
this.InvalidElementStateError = function(msg) {