summaryrefslogtreecommitdiff
path: root/test/unit/test_shell.py
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2022-08-25 07:38:36 +0000
committerGerrit Code Review <review@openstack.org>2022-08-25 07:38:36 +0000
commit662e530d8d4e8e74ba087733f1f51cb98d5145cc (patch)
treeb281d66873c596213b6a80fb683eb7ef0b1bafa2 /test/unit/test_shell.py
parent02509acc71e6f609b6a9f3c8055479872bedaf2a (diff)
parentdefbb4a8f390c7de73ac6a90fc1ab5009e8105ee (diff)
downloadpython-swiftclient-4.1.0.tar.gz
Merge "Allow tempurl times to have units"4.1.0
Diffstat (limited to 'test/unit/test_shell.py')
-rw-r--r--test/unit/test_shell.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/unit/test_shell.py b/test/unit/test_shell.py
index f6af6cb..98d73e9 100644
--- a/test/unit/test_shell.py
+++ b/test/unit/test_shell.py
@@ -2079,6 +2079,14 @@ class TestShell(unittest.TestCase):
'/v1/AUTH_account/c/o', "60", 'secret_key', 'GET', absolute=False,
iso8601=False, prefix=False, ip_range=None, digest='sha256')
+ # sanity check that suffixes will just pass through to utils.py
+ argv = ["", "tempurl", "GET", "2d", "/v1/AUTH_account/c/o",
+ "secret_key"]
+ swiftclient.shell.main(argv)
+ temp_url.assert_called_with(
+ '/v1/AUTH_account/c/o', "2d", 'secret_key', 'GET', absolute=False,
+ iso8601=False, prefix=False, ip_range=None, digest='sha256')
+
@mock.patch('swiftclient.shell.generate_temp_url', return_value='')
def test_temp_url_prefix_based(self, temp_url):
argv = ["", "tempurl", "GET", "60", "/v1/AUTH_account/c/",