Skip to content

Commit 954ffce

Browse files
committed
fix test
1 parent 5e04104 commit 954ffce

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

test/asynchronous/test_auth.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,10 @@ async def test_gssapi_simple(self):
168168
await client[GSSAPI_DB].collection.find_one()
169169

170170
# Log in using URI, with authMechanismProperties.
171-
mech_uri = uri + f"&authMechanismProperties={self.mech_properties}"
171+
mech_properties_str = ""
172+
for key, value in self.mech_properties:
173+
mech_properties_str += f"{key}:{value},"
174+
mech_uri = uri + f"&authMechanismProperties={mech_properties_str[:-1]}"
172175
client = self.simple_client(mech_uri)
173176
await client[GSSAPI_DB].collection.find_one()
174177

test/test_auth.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,10 @@ def test_gssapi_simple(self):
168168
client[GSSAPI_DB].collection.find_one()
169169

170170
# Log in using URI, with authMechanismProperties.
171-
mech_uri = uri + f"&authMechanismProperties={self.mech_properties}"
171+
mech_properties_str = ""
172+
for key, value in self.mech_properties:
173+
mech_properties_str += f"{key}:{value},"
174+
mech_uri = uri + f"&authMechanismProperties={mech_properties_str[:-1]}"
172175
client = self.simple_client(mech_uri)
173176
client[GSSAPI_DB].collection.find_one()
174177

0 commit comments

Comments
 (0)