diff options
| author | ZhijunWei <wzj334965317@outlook.com> | 2018-12-28 23:04:37 +0800 |
|---|---|---|
| committer | ZhijunWei <wzj334965317@outlook.com> | 2019-01-03 13:09:22 +0800 |
| commit | 2ff36fde575fa6987ee5954f526ad6c9460633a5 (patch) | |
| tree | 1166328403d7c4d69f5e3df8d12c159264b9e886 /tests | |
| parent | 4e4f57a5fc5e5f025816eb1672abfea020b208a0 (diff) | |
| download | python-swiftclient-2ff36fde575fa6987ee5954f526ad6c9460633a5.tar.gz | |
Update hacking version
1. update hacking version to latest
2. fix pep8 failed
Change-Id: Ifc3bfeff4038c93d8c8cf2c9d7814c3003e73504
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/unit/test_shell.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/unit/test_shell.py b/tests/unit/test_shell.py index 9ef4685..f5d2f15 100644 --- a/tests/unit/test_shell.py +++ b/tests/unit/test_shell.py @@ -1996,8 +1996,8 @@ class TestBase(unittest.TestCase): self._environ_vars = {} keys = list(os.environ.keys()) for k in keys: - if (k in ('ST_KEY', 'ST_USER', 'ST_AUTH') - or k.startswith('OS_')): + if (k in ('ST_KEY', 'ST_USER', 'ST_AUTH') or + k.startswith('OS_')): self._environ_vars[k] = os.environ.pop(k) def _replace_swift_env_vars(self): @@ -2979,12 +2979,12 @@ class TestCrossAccountObjectAccess(TestBase, MockHttpTest): Modify response code to 200 if cross account permissions match. """ status = 403 - if (path.startswith('/v1/%s/%s' % (self.account, self.cont)) - and read_ok and method in ('GET', 'HEAD')): + if (path.startswith('/v1/%s/%s' % (self.account, self.cont)) and + read_ok and method in ('GET', 'HEAD')): status = 200 elif (path.startswith('/v1/%s/%s%s' - % (self.account, self.cont, self.obj)) - and write_ok and method in ('PUT', 'POST', 'DELETE')): + % (self.account, self.cont, self.obj)) and + write_ok and method in ('PUT', 'POST', 'DELETE')): status = 200 return status return on_request |
