diff --git a/tools/wptrunner/wptrunner/executors/executormarionette.py b/tools/wptrunner/wptrunner/executors/executormarionette.py index 95f186082042e3..a3b56fe08df11e 100644 --- a/tools/wptrunner/wptrunner/executors/executormarionette.py +++ b/tools/wptrunner/wptrunner/executors/executormarionette.py @@ -48,10 +48,11 @@ def do_delayed_imports(): - global errors, marionette, Addons + global errors, marionette, Addons, WebAuthn from marionette_driver import marionette, errors from marionette_driver.addons import Addons + from marionette_driver.webauthn import WebAuthn def _switch_to_window(marionette, handle): @@ -590,28 +591,28 @@ def generate_test_report(self, config): class MarionetteVirtualAuthenticatorProtocolPart(VirtualAuthenticatorProtocolPart): def setup(self): - self.marionette = self.parent.marionette + self.webauthn = WebAuthn(self.parent.marionette) def add_virtual_authenticator(self, config): - raise NotImplementedError("add_virtual_authenticator not yet implemented") + return self.webauthn.add_virtual_authenticator(config) def remove_virtual_authenticator(self, authenticator_id): - raise NotImplementedError("remove_virtual_authenticator not yet implemented") + self.webauthn.remove_virtual_authenticator(authenticator_id) def add_credential(self, authenticator_id, credential): - raise NotImplementedError("add_credential not yet implemented") + self.webauthn.add_credential(authenticator_id, credential) def get_credentials(self, authenticator_id): - raise NotImplementedError("get_credentials not yet implemented") + return self.webauthn.get_credentials(authenticator_id) def remove_credential(self, authenticator_id, credential_id): - raise NotImplementedError("remove_credential not yet implemented") + self.webauthn.remove_credential(authenticator_id, credential_id) def remove_all_credentials(self, authenticator_id): - raise NotImplementedError("remove_all_credentials not yet implemented") + self.webauthn.remove_all_credentials(authenticator_id) def set_user_verified(self, authenticator_id, uv): - raise NotImplementedError("set_user_verified not yet implemented") + self.webauthn.set_user_verified(authenticator_id, uv) class MarionetteSetPermissionProtocolPart(SetPermissionProtocolPart):