From d3955243073b9602ef84bdef8d53946a8de5bdcd Mon Sep 17 00:00:00 2001 From: Martin Pitt Date: Thu, 4 Feb 2016 14:08:40 +0100 Subject: [PATCH] mock_swift.py: Use status code 401 on nonexisting container, like the real Swift --- tests/mock_swift.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/mock_swift.py b/tests/mock_swift.py index 5703c63..ecaa2fc 100644 --- a/tests/mock_swift.py +++ b/tests/mock_swift.py @@ -84,7 +84,7 @@ class SwiftHTTPRequestHandler(BaseHTTPRequestHandler): try: objs = set(['%s/result.tar' % r for r in self.results[container]]) except KeyError: - self.send_error(404, 'Container does not exist') + self.send_error(401, 'Container does not exist') return if 'prefix' in query: p = query['prefix'][-1]