File tree Expand file tree Collapse file tree 3 files changed +4
-10
lines changed Expand file tree Collapse file tree 3 files changed +4
-10
lines changed Original file line number Diff line number Diff line change 2121 from types import MappingProxyType
2222
2323 from .authentication import Authenticator
24- from .const import (
25- DataType ,
26- )
24+ from .const import DataType
2725 from .event_bus import EventBus
2826 from .models import ApiDeviceInfo
2927
Original file line number Diff line number Diff line change @@ -57,13 +57,10 @@ async def assert_command(
5757) -> None :
5858 command_result = command_result or CommandResult .success ()
5959 event_bus = Mock (spec_set = EventBus )
60- authenticator = Mock (
61- spec_set = Authenticator ,
62- )
60+ authenticator = Mock (spec_set = Authenticator )
6361 authenticator .authenticate = AsyncMock (
6462 return_value = Credentials ("token" , "user_id" , 9999 )
6563 )
66-
6764 if isinstance (json_api_response , tuple ):
6865 mock = AsyncMock (side_effect = json_api_response )
6966 else :
Original file line number Diff line number Diff line change 1212from deebot_client .authentication import (
1313 Authenticator ,
1414 RestConfiguration ,
15- UserAuthenticator ,
1615 create_rest_config as create_config_rest ,
1716)
1817from deebot_client .event_bus import EventBus
@@ -59,8 +58,8 @@ def rest_config(
5958
6059
6160@pytest .fixture
62- def authenticator () -> UserAuthenticator :
63- authenticator = Mock (spec_set = UserAuthenticator )
61+ def authenticator () -> Authenticator :
62+ authenticator = Mock (spec_set = Authenticator )
6463 authenticator .authenticate .return_value = Credentials ("token" , "user_id" , 9999 )
6564 authenticator .execute_command_request .return_value = (
6665 authenticator .post_authenticated .return_value
You can’t perform that action at this time.
0 commit comments