diff options
author | Dan Mick <dan.mick@inktank.com> | 2013-07-25 21:41:32 -0700 |
---|---|---|
committer | Dan Mick <dan.mick@inktank.com> | 2013-07-25 21:41:32 -0700 |
commit | 47d0937ccb553b3e0d447b792ba6b6ca30ae96f7 (patch) | |
tree | ea51688601f1c032de89be2d4555ca2a5f319eaf | |
parent | 6951d2345a5d837c3b14103bd4d8f5ee4407c937 (diff) | |
download | ceph-47d0937ccb553b3e0d447b792ba6b6ca30ae96f7.tar.gz |
rest/test.py: earlier versions of requests.py don't quote ' ' in params
requests 0.12.1 handles queryparams in the URL with embedded
spaces; requests 0.8.2 does not. Avoid the issue by quoting the
URL into expect().
Signed-off-by: Dan Mick <dan.mick@inktank.com>
-rwxr-xr-x | qa/workunits/rest/test.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/qa/workunits/rest/test.py b/qa/workunits/rest/test.py index 60dabab9678..f0cf1f2c761 100755 --- a/qa/workunits/rest/test.py +++ b/qa/workunits/rest/test.py @@ -72,7 +72,7 @@ if __name__ == '__main__': expect('auth/export', 'GET', 200, 'xml', XMLHDR) expect('auth/add?entity=client.xx&' - 'caps=mon&caps=allow&caps=osd&caps=allow *', 'PUT', 200, 'json', + 'caps=mon&caps=allow&caps=osd&caps=allow+*', 'PUT', 200, 'json', JSONHDR) r = expect('auth/export?entity=client.xx', 'GET', 200, 'plain') @@ -95,7 +95,7 @@ if __name__ == '__main__': expect('auth/print-key?entity=client.xx', 'GET', 200, 'json', JSONHDR) expect('auth/print_key?entity=client.xx', 'GET', 200, 'json', JSONHDR) - expect('auth/caps?entity=client.xx&caps=osd&caps=allow rw', 'PUT', 200, + expect('auth/caps?entity=client.xx&caps=osd&caps=allow+rw', 'PUT', 200, 'json', JSONHDR) r = expect('auth/list.json', 'GET', 200, 'json') dictlist = r.myjson['output']['auth_dump'] |