From d04d12bdf9e76ca1fc15486e0edd9094357f8db7 Mon Sep 17 00:00:00 2001 From: Chandan Kumar Date: Mon, 29 Jan 2018 12:00:08 +0530 Subject: [PATCH] Synced tempest code from monasca-{api, log_api} * Fix Metric Statistics period call, Statistics api failure when end time is not used from monasca-api and Enable UWSGI support in monasca-log-api from monasca-log-api code synced. Change-Id: I2ce2bd8238d44a451faeba9ddbfe27d900e9adef --- .../tests/log_api/test_constraints.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/monasca_tempest_tests/tests/log_api/test_constraints.py b/monasca_tempest_tests/tests/log_api/test_constraints.py index 00c1212..cf81166 100644 --- a/monasca_tempest_tests/tests/log_api/test_constraints.py +++ b/monasca_tempest_tests/tests/log_api/test_constraints.py @@ -75,8 +75,11 @@ class TestLogApiConstraints(base.BaseLogsTestCase): except exceptions.OverLimit as urc: self.assertEqual(413, urc.resp.status) return + except exceptions.UnexpectedContentType as uct: + self.assertEqual(503, uct.resp.status) + return - self.assertTrue(False, 'API should respond with 413') + self.assertTrue(False, 'API should respond with 413 or 503') @decorators.attr(type='gate') def test_should_reject_too_big_message_multiline(self): @@ -97,5 +100,8 @@ class TestLogApiConstraints(base.BaseLogsTestCase): except exceptions.OverLimit as urc: self.assertEqual(413, urc.resp.status) return + except exceptions.UnexpectedContentType as uct: + self.assertEqual(503, uct.resp.status) + return - self.assertTrue(False, 'API should respond with 413') + self.assertTrue(False, 'API should respond with 413 or 503')