(self)
| 445 | await self.connect(user=self.realm.user_princ, krbsrvname='wrong') |
| 446 | |
| 447 | async def test_auth_gssapi_bad_user(self): |
| 448 | # Credentials mismatch. |
| 449 | with self.assertRaisesRegex( |
| 450 | exceptions.InvalidAuthorizationSpecificationError, |
| 451 | 'GSSAPI authentication failed for user' |
| 452 | ): |
| 453 | await self.connect(user=f'wrong-{self.realm.user_princ}') |
| 454 | |
| 455 | |
| 456 | @unittest.skipIf(_system != 'Windows', 'SSPI is only available on Windows') |