Add a zero chunk test to cloud storage
This commit is contained in:
parent
165486180d
commit
a20d758642
1 changed files with 4 additions and 1 deletions
|
@ -84,6 +84,9 @@ class TestCloudStorage(unittest.TestCase):
|
|||
self.engine.stream_write(_TEST_PATH, StringIO(new_data), content_type='Cool/Type')
|
||||
self.assertEquals(new_data, self.engine.get_content(_TEST_PATH))
|
||||
|
||||
def test_chunked_upload_no_chunks(self):
|
||||
self._chunk_upload_test(0)
|
||||
|
||||
def test_chunked_upload_single_chunk(self):
|
||||
self._chunk_upload_test(1)
|
||||
|
||||
|
@ -114,7 +117,7 @@ class TestCloudStorage(unittest.TestCase):
|
|||
self.assertEquals(index + 1, len(metadata[_CHUNKS_KEY]))
|
||||
|
||||
# Complete the chunked upload.
|
||||
self.engine.complete_chunked_upload(upload_id, 'some/chunked/path', new_metadata,
|
||||
self.engine.complete_chunked_upload(upload_id, 'some/chunked/path', metadata,
|
||||
force_client_side=force_client_side)
|
||||
|
||||
# Ensure the file contents are valid.
|
||||
|
|
Reference in a new issue