Skip to content

Commit

Permalink
'Refactored by Sourcery'
Browse files Browse the repository at this point in the history
  • Loading branch information
Sourcery AI committed Jul 13, 2022
1 parent 94ef8bf commit 8b3770a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
7 changes: 4 additions & 3 deletions tests/_async/test_client_with_auto_confirm_enabled.py
Original file line number Diff line number Diff line change
Expand Up @@ -338,10 +338,10 @@ async def test_get_update_user_after_sign_out(client: AsyncGoTrueClient):
@pytest.mark.depends(on=[test_get_user_after_sign_out.__name__])
async def test_sign_in_with_the_wrong_password(client: AsyncGoTrueClient):
try:
await client.sign_in(email=email, password=password + "2")
await client.sign_in(email=email, password=f"{password}2")
assert False
except APIError:
assert True
pass
except Exception as e:
assert False, str(e)

Expand Down Expand Up @@ -420,8 +420,9 @@ async def test_get_session_from_url_errors(client: AsyncGoTrueClient):
error_description = fake.email()
try:
await client.get_session_from_url(
url=dummy_url + f"?error_description={error_description}"
url=f"{dummy_url}?error_description={error_description}"
)

assert False
except APIError as e:
assert e.code == 400
Expand Down
7 changes: 4 additions & 3 deletions tests/_sync/test_client_with_auto_confirm_enabled.py
Original file line number Diff line number Diff line change
Expand Up @@ -332,10 +332,10 @@ def test_get_update_user_after_sign_out(client: SyncGoTrueClient):
@pytest.mark.depends(on=[test_get_user_after_sign_out.__name__])
def test_sign_in_with_the_wrong_password(client: SyncGoTrueClient):
try:
client.sign_in(email=email, password=password + "2")
client.sign_in(email=email, password=f"{password}2")
assert False
except APIError:
assert True
pass
except Exception as e:
assert False, str(e)

Expand Down Expand Up @@ -414,8 +414,9 @@ def test_get_session_from_url_errors(client: SyncGoTrueClient):
error_description = fake.email()
try:
client.get_session_from_url(
url=dummy_url + f"?error_description={error_description}"
url=f"{dummy_url}?error_description={error_description}"
)

assert False
except APIError as e:
assert e.code == 400
Expand Down

0 comments on commit 8b3770a

Please sign in to comment.