Skip to content

Commit

Permalink
Fixed test has_calls on Python 3.12 (#1936)
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-astus authored Dec 10, 2024
1 parent daa2e22 commit ca0879b
Showing 1 changed file with 16 additions and 10 deletions.
26 changes: 16 additions & 10 deletions tests/test_connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -1219,16 +1219,22 @@ def test_generate_jwt_with_passphrase(
result.output
== "Enter private key file password (press enter for empty) []: \nfunny token\n"
)
mocked_get_token.has_calls(
mock.call(
user="FooBar", account="account1", privatekey_path=str(f), key_password=None
),
mock.call(
user="FooBar",
account="account1",
privatekey_path=str(f),
key_password=passphrase,
),
mocked_get_token.assert_has_calls(
[
mock.call(
user="FooBar",
account="account1",
privatekey_path=str(f),
key_password=None,
),
mock.call(
user="FooBar",
account="account1",
privatekey_path=str(f),
key_password=passphrase,
),
],
any_order=True,
)


Expand Down

0 comments on commit ca0879b

Please sign in to comment.