jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/345172 )
Change subject: test_https_cert_error: Ignore other warnings ......................................................................
test_https_cert_error: Ignore other warnings
Make sure InsecureRequestWarning is raised but ignore other warnings.
Bug: T161371 Change-Id: I5aed8de8739a4d955320be2c1cb9da00ab6c0ae7 --- M tests/http_tests.py 1 file changed, 2 insertions(+), 3 deletions(-)
Approvals: jenkins-bot: Verified Xqt: Looks good to me, approved
diff --git a/tests/http_tests.py b/tests/http_tests.py index c1ce2f0..af3e5d9 100644 --- a/tests/http_tests.py +++ b/tests/http_tests.py @@ -159,9 +159,8 @@ http.session.close() # clear the connection
# Verify that the warning occurred - self.assertEqual(len(warning_log), 1) - self.assertEqual(warning_log[0].category.__name__, - 'InsecureRequestWarning') + self.assertIn('InsecureRequestWarning', + [w.category.__name__ for w in warning_log])
class TestHttpStatus(HttpbinTestCase):
pywikibot-commits@lists.wikimedia.org