From 40a355a42d4a9444dc753c04c6608dade2f06a23 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 03:13:27 +0200 Subject: Adding upstream version 125.0.1. Signed-off-by: Daniel Baumann --- remote/shared/webdriver/Errors.sys.mjs | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'remote/shared/webdriver/Errors.sys.mjs') diff --git a/remote/shared/webdriver/Errors.sys.mjs b/remote/shared/webdriver/Errors.sys.mjs index 53b9d4426b..7060131075 100644 --- a/remote/shared/webdriver/Errors.sys.mjs +++ b/remote/shared/webdriver/Errors.sys.mjs @@ -41,6 +41,7 @@ const ERRORS = new Set([ "TimeoutError", "UnableToCaptureScreen", "UnableToSetCookieError", + "UnableToSetFileInputError", "UnexpectedAlertOpenError", "UnknownCommandError", "UnknownError", @@ -756,6 +757,21 @@ class UnableToSetCookieError extends WebDriverError { } } +/** + * A command to set a file could not be satisfied. + * + * @param {string=} message + * Optional string describing error situation. + * @param {object=} data + * Additional error data helpful in diagnosing the error. + */ +class UnableToSetFileInputError extends WebDriverError { + constructor(message, data = {}) { + super(message, data); + this.status = "unable to set file input"; + } +} + /** * A command to capture a screenshot could not be satisfied. * @@ -865,6 +881,7 @@ const STATUSES = new Map([ ["timeout", TimeoutError], ["unable to capture screen", UnableToCaptureScreen], ["unable to set cookie", UnableToSetCookieError], + ["unable to set file input", UnableToSetFileInputError], ["unexpected alert open", UnexpectedAlertOpenError], ["unknown command", UnknownCommandError], ["unknown error", UnknownError], -- cgit v1.2.3