Commit e9ef74fd authored by Łukasz Nowak's avatar Łukasz Nowak

rapid-cdn: Fix test instability

In case of unavailable backend 502 and 503 are the possible codes, so relax
the assertion.
parent 11d198d0
...@@ -2584,10 +2584,10 @@ class TestSlave(SlaveHttpFrontendTestCase, TestDataMixin, AtsMixin): ...@@ -2584,10 +2584,10 @@ class TestSlave(SlaveHttpFrontendTestCase, TestDataMixin, AtsMixin):
self.certificate_pem, self.certificate_pem,
result.certificate) result.certificate)
self.assertEqual( # 502 and 503 are both ok as response codes by the backend-haproxy
self.assertIn(
result.status_code, result.status_code,
http.client.BAD_GATEWAY [http.client.BAD_GATEWAY, http.client.SERVICE_UNAVAILABLE])
)
finally: finally:
self.stopAuthenticatedServerProcess() self.stopAuthenticatedServerProcess()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment