diff options
author | Joffrey F <joffrey@docker.com> | 2018-02-13 15:17:03 -0800 |
---|---|---|
committer | Joffrey F <joffrey@docker.com> | 2018-02-14 16:07:19 -0800 |
commit | 581ccc9f7e8e189248054268c98561ca775bd3d7 (patch) | |
tree | 682c25e7e624ecf6933a918b869f990950798d2f /tests/unit/models_containers_test.py | |
parent | 9e75609aec497361068bd0f57d5cc24065621106 (diff) | |
download | docker-py-1352-data_stream_control.tar.gz |
Add chunk_size parameter to data downloading methods (export, get_archive, save)1352-data_stream_control
Signed-off-by: Joffrey F <joffrey@docker.com>
Diffstat (limited to 'tests/unit/models_containers_test.py')
-rw-r--r-- | tests/unit/models_containers_test.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/tests/unit/models_containers_test.py b/tests/unit/models_containers_test.py index f79f5d5..2b0b499 100644 --- a/tests/unit/models_containers_test.py +++ b/tests/unit/models_containers_test.py @@ -1,4 +1,5 @@ import docker +from docker.constants import DEFAULT_DATA_CHUNK_SIZE from docker.models.containers import Container, _create_container_args from docker.models.images import Image import unittest @@ -422,13 +423,17 @@ class ContainerTest(unittest.TestCase): client = make_fake_client() container = client.containers.get(FAKE_CONTAINER_ID) container.export() - client.api.export.assert_called_with(FAKE_CONTAINER_ID) + client.api.export.assert_called_with( + FAKE_CONTAINER_ID, DEFAULT_DATA_CHUNK_SIZE + ) def test_get_archive(self): client = make_fake_client() container = client.containers.get(FAKE_CONTAINER_ID) container.get_archive('foo') - client.api.get_archive.assert_called_with(FAKE_CONTAINER_ID, 'foo') + client.api.get_archive.assert_called_with( + FAKE_CONTAINER_ID, 'foo', DEFAULT_DATA_CHUNK_SIZE + ) def test_image(self): client = make_fake_client() |