Skip to content

Commit 1321e37

Browse files
Fix username/password validation in broker test (#807)
* Fix username/password assert in broker test Signed-off-by: Emmanuel Ferdman <[email protected]> * Update tests/broker-test.py Co-authored-by: Ray Luo <[email protected]> --------- Signed-off-by: Emmanuel Ferdman <[email protected]> Co-authored-by: Ray Luo <[email protected]>
1 parent 4eb7bd1 commit 1321e37

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/broker-test.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,10 +71,10 @@ def test_broker_username_password(scopes, expected_token_type):
7171
print("Testing broker username password flows by using accounts in local .env")
7272
username = os.getenv("BROKER_TEST_ACCOUNT") or input("Input test account for broker test: ")
7373
password = os.getenv("BROKER_TEST_ACCOUNT_PASSWORD") or getpass.getpass("Input test account's password: ")
74-
assert(username and password, "You need to provide a test account and its password")
74+
assert username and password, "You need to provide a test account and its password"
7575
result = pca.acquire_token_by_username_password(username, password, scopes)
7676
_assert(result, expected_token_type)
77-
assert(result.get("token_source") == "broker")
77+
assert result.get("token_source") == "broker"
7878
print("Username password test succeeds.")
7979

8080
def _assert(result, expected_token_type):

0 commit comments

Comments
 (0)