Skip to content

Commit

Permalink
test: fix tests for python <3.10
Browse files Browse the repository at this point in the history
  • Loading branch information
jooola committed Aug 8, 2023
1 parent 4344358 commit 703a476
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/unit/servers/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ def test_rebuild(self, hetzner_client, bound_server, generic_action):

assert response.action.id == 1
assert response.action.progress == 0
assert isinstance(response.root_password, str | None)
assert response.root_password is None or isinstance(response.root_password, str)

def test_enable_backup(self, hetzner_client, bound_server, generic_action):
hetzner_client.request.return_value = generic_action
Expand Down Expand Up @@ -1049,7 +1049,7 @@ def test_rebuild(self, servers_client, server, generic_action):

assert response.action.id == 1
assert response.action.progress == 0
assert isinstance(response.root_password, str | None)
assert response.root_password is None or isinstance(response.root_password, str)

def test_rebuild_return_response_deprecation(self, servers_client, generic_action):
servers_client._client.request.return_value = generic_action
Expand Down

0 comments on commit 703a476

Please sign in to comment.