зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1713775 - [marionette] Fail session creation if the webSocketUrl capability is passed r=remote-protocol-reviewers,marionette-reviewers,jgraham
Until a BiDi implementation can be successfully started, creating a session with the webSocketUrl capability should throw. Differential Revision: https://phabricator.services.mozilla.com/D116590
This commit is contained in:
Родитель
d90d1a148c
Коммит
1ee8695215
|
@ -650,6 +650,11 @@ class Capabilities extends Map {
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case "webSocketUrl":
|
||||||
|
throw new error.InvalidArgumentError(
|
||||||
|
"webSocketURL is not supported yet"
|
||||||
|
);
|
||||||
|
|
||||||
case "moz:accessibilityChecks":
|
case "moz:accessibilityChecks":
|
||||||
assert.boolean(v, pprint`Expected ${k} to be boolean, got ${v}`);
|
assert.boolean(v, pprint`Expected ${k} to be boolean, got ${v}`);
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -614,6 +614,7 @@ add_test(function test_Capabilities_fromJSON() {
|
||||||
() => fromJSON({ "moz:webdriverClick": 1 }),
|
() => fromJSON({ "moz:webdriverClick": 1 }),
|
||||||
/InvalidArgumentError/
|
/InvalidArgumentError/
|
||||||
);
|
);
|
||||||
|
Assert.throws(() => fromJSON({ webSocketUrl: true }), /InvalidArgumentError/);
|
||||||
|
|
||||||
run_next_test();
|
run_next_test();
|
||||||
});
|
});
|
||||||
|
|
|
@ -249,3 +249,9 @@ class TestCapabilityMatching(MarionetteTestCase):
|
||||||
SessionNotCreatedException, "InvalidArgumentError"
|
SessionNotCreatedException, "InvalidArgumentError"
|
||||||
):
|
):
|
||||||
self.marionette.start_session({"unhandledPromptBehavior": behavior})
|
self.marionette.start_session({"unhandledPromptBehavior": behavior})
|
||||||
|
|
||||||
|
def test_web_socket_url(self):
|
||||||
|
with self.assertRaisesRegexp(
|
||||||
|
SessionNotCreatedException, "InvalidArgumentError"
|
||||||
|
):
|
||||||
|
self.marionette.start_session({"webSocketUrl": True})
|
||||||
|
|
Загрузка…
Ссылка в новой задаче