jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/458465 )
Change subject: [fix] Skip QueryStringParamsTestCase.test_no_params() for status 503 ......................................................................
[fix] Skip QueryStringParamsTestCase.test_no_params() for status 503
Skip http_tests.QueryStringParamsTestCase.test_no_params() for status 503
Bug: T203637 Change-Id: Ie3e26e409c37f5dbfff2c92123d91713f0d4ee9d --- M tests/http_tests.py 1 file changed, 17 insertions(+), 4 deletions(-)
Approvals: Framawiki: Looks good to me, approved jenkins-bot: Verified
diff --git a/tests/http_tests.py b/tests/http_tests.py index 6b6c89d..5125eec 100644 --- a/tests/http_tests.py +++ b/tests/http_tests.py @@ -643,9 +643,17 @@ urldecoded query string parameters. """
+ def setUp(self): + """Set up tests.""" + super(QueryStringParamsTestCase, self).setUp() + self.url = self.get_httpbin_url('/get') + def test_no_params(self): """Test fetch method with no parameters.""" - r = http.fetch(uri=self.get_httpbin_url('/get'), params={}) + r = http.fetch(uri=self.url, params={}) + if r.status == 503: # T203637 + unittest.skipTest('503: Service currently not available for ' + + self.url) self.assertEqual(r.status, 200)
content = json.loads(r.text) @@ -658,7 +666,10 @@ HTTPBin returns the args in their urldecoded form, so what we put in should be the same as what we get out. """ - r = http.fetch(uri=self.get_httpbin_url('/get'), params={'fish&chips': 'delicious'}) + r = http.fetch(uri=self.url, params={'fish&chips': 'delicious'}) + if r.status == 503: # T203637 + unittest.skipTest('503: Service currently not available for ' + + self.url) self.assertEqual(r.status, 200)
content = json.loads(r.text) @@ -671,8 +682,10 @@ HTTPBin returns the args in their urldecoded form, so what we put in should be the same as what we get out. """ - r = http.fetch(uri=self.get_httpbin_url('/get'), - params={'fish%26chips': 'delicious'}) + r = http.fetch(uri=self.url, params={'fish%26chips': 'delicious'}) + if r.status == 503: # T203637 + unittest.skipTest('503: Service currently not available for ' + + self.url) self.assertEqual(r.status, 200)
content = json.loads(r.text)