diff options
author | Wu Wenxiang <wu.wenxiang@99cloud.net> | 2013-08-02 20:51:58 +0800 |
---|---|---|
committer | Wu Wenxiang <wu.wenxiang@99cloud.net> | 2013-08-02 20:57:02 +0800 |
commit | 256978a0eea5238bb1f1896a1108616d3b3ed292 (patch) | |
tree | 5060cd6eea470650c24011087cffa0243a5f836c | |
parent | 9198e95468b3005730c931da1701f34b1a9ce2d9 (diff) | |
download | python-swiftclient-256978a0eea5238bb1f1896a1108616d3b3ed292.tar.gz |
Assignment to reserved built-in symbol "file"
In file: tests/test_swiftclient.py, test_unicode_ok() &
test_chunk_warning()
Fixes bug #1207736
Change-Id: I0a822802ec8910e9aec36ae5af775f8abb384d34
-rw-r--r-- | tests/test_swiftclient.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/test_swiftclient.py b/tests/test_swiftclient.py index a072878..7a10d34 100644 --- a/tests/test_swiftclient.py +++ b/tests/test_swiftclient.py @@ -539,12 +539,12 @@ class TestPutObject(MockHttpTest): def test_unicode_ok(self): conn = c.http_connection(u'http://www.test.com/') - file = StringIO.StringIO(u'\u5929\u7a7a\u4e2d\u7684\u4e4c\u4e91') + mock_file = StringIO.StringIO(u'\u5929\u7a7a\u4e2d\u7684\u4e4c\u4e91') args = (u'\u5929\u7a7a\u4e2d\u7684\u4e4c\u4e91', '\u5929\u7a7a\u4e2d\u7684\u4e4c\u4e91', u'\u5929\u7a7a\u4e2d\u7684\u4e4c\u4e91', u'\u5929\u7a7a\u4e2d\u7684\u4e4c\u4e91', - file) + mock_file) headers = {'X-Header1': u'\u5929\u7a7a\u4e2d\u7684\u4e4c\u4e91', 'X-2': 1, 'X-3': {'a': 'b'}, 'a-b': '.x:yz mn:fg:lp'} @@ -559,8 +559,8 @@ class TestPutObject(MockHttpTest): def test_chunk_warning(self): conn = c.http_connection('http://www.test.com/') - file = StringIO.StringIO('asdf') - args = ('asdf', 'asdf', 'asdf', 'asdf', file) + mock_file = StringIO.StringIO('asdf') + args = ('asdf', 'asdf', 'asdf', 'asdf', mock_file) resp = MockHttpResponse() conn[1].getresponse = resp.fake_response conn[1].send = resp.fake_send |