diff --git a/glance/tests/functional/test_cors_middleware.py b/glance/tests/functional/test_cors_middleware.py index d2a1156297..5484e2b786 100644 --- a/glance/tests/functional/test_cors_middleware.py +++ b/glance/tests/functional/test_cors_middleware.py @@ -43,7 +43,7 @@ class TestCORSMiddleware(functional.FunctionalTest): 'Access-Control-Request-Method': 'GET' }) - self.assertEqual(r_headers.status, 200) + self.assertEqual(200, r_headers.status) self.assertIn('access-control-allow-origin', r_headers) self.assertEqual('http://valid.example.com', r_headers['access-control-allow-origin']) @@ -57,7 +57,7 @@ class TestCORSMiddleware(functional.FunctionalTest): 'Access-Control-Request-Method': 'GET' }) - self.assertEqual(r_headers.status, 200) + self.assertEqual(200, r_headers.status) self.assertNotIn('access-control-allow-origin', r_headers) def test_valid_cors_get_request(self): @@ -68,7 +68,7 @@ class TestCORSMiddleware(functional.FunctionalTest): 'Origin': 'http://valid.example.com' }) - self.assertEqual(r_headers.status, 200) + self.assertEqual(200, r_headers.status) self.assertIn('access-control-allow-origin', r_headers) self.assertEqual('http://valid.example.com', r_headers['access-control-allow-origin']) @@ -81,5 +81,5 @@ class TestCORSMiddleware(functional.FunctionalTest): 'Origin': 'http://invalid.example.com' }) - self.assertEqual(r_headers.status, 200) + self.assertEqual(200, r_headers.status) self.assertNotIn('access-control-allow-origin', r_headers)