MCPcopy Index your code
hub / github.com/MagicStack/asyncpg / test_auth_password_cleartext

Method test_auth_password_cleartext

tests/test_connect.py:256–267  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

254 await self._try_connect(user='reject_user')
255
256 async def test_auth_password_cleartext(self):
257 conn = await self.connect(
258 user='password_user',
259 password=CORRECT_PASSWORD)
260 await conn.close()
261
262 with self.assertRaisesRegex(
263 asyncpg.InvalidPasswordError,
264 'password authentication failed for user "password_user"'):
265 await self._try_connect(
266 user='password_user',
267 password='wrongpassword')
268
269 async def test_auth_password_cleartext_callable(self):
270 def get_correctpassword():

Callers

nothing calls this directly

Calls 3

_try_connectMethod · 0.95
connectMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected