jenkins-bot merged this change.
test(test_login_logout): fix AssertionError
Follow up to c4fbf0c, two consecutive logouts does not raise
AssertionError anymore.
It was somewhat wrong to rely on this error anyway, because assert
statements are not reliable in Python (they are skipped when the
-O is passed to the interpreter.)
Change-Id: Ie4e99ef80b022c527865fd703b33dee4654b8ae9
---
M tests/site_tests.py
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/tests/site_tests.py b/tests/site_tests.py
index d4baea1..63d5cc2 100644
--- a/tests/site_tests.py
+++ b/tests/site_tests.py
@@ -3718,9 +3718,7 @@
self.assertEqual(site._loginstatus, loginstatus.NOT_LOGGED_IN)
self.assertNotIn('_userinfo', site.__dict__.keys())
- self.assertRaisesRegexp(AssertionError,
- 'User must login in this site',
- site.logout)
+ self.assertIsNone(site.user())
if __name__ == '__main__': # pragma: no cover
To view, visit change 517030. To unsubscribe, or for help writing mail filters, visit settings.