summaryrefslogtreecommitdiff
path: root/openstackclient/tests/unit
diff options
context:
space:
mode:
authorSimon Merrick <simonmerrick@catalyst.net.nz>2020-11-19 20:05:54 +1300
committerAlan Pevec <alan.pevec@redhat.com>2021-05-28 22:36:43 +0000
commit8dbf141d52c84d0a7311e62d39d229fdc80876fd (patch)
tree8189d239457d486adf3ae7587e1ef47742b0575f /openstackclient/tests/unit
parent94ae417b5121187dec5334f51ce79c6efb3c8bd6 (diff)
downloadpython-openstackclient-8dbf141d52c84d0a7311e62d39d229fdc80876fd.tar.gz
stop image downloads to memory
+ Fixes issue with large images hogging memory + stream image downloads + output to stdout if file not specified Change-Id: Ia01ff9b21a2dac5d0ccf2bd58a8640e88c5cbb36 Story: 2007672 Task: 39776 (cherry picked from commit 5bdcd590ecacbc0aa8db2cbafa0ab1a9f3c28ce0)
Diffstat (limited to 'openstackclient/tests/unit')
-rw-r--r--openstackclient/tests/unit/image/v2/test_image.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/openstackclient/tests/unit/image/v2/test_image.py b/openstackclient/tests/unit/image/v2/test_image.py
index 310f6b76..a7f60398 100644
--- a/openstackclient/tests/unit/image/v2/test_image.py
+++ b/openstackclient/tests/unit/image/v2/test_image.py
@@ -1614,7 +1614,7 @@ class TestImageSave(TestImage):
verifylist = [
('file', '/path/to/file'),
- ('image', self.image.id)
+ ('image', self.image.id),
]
parsed_args = self.check_parser(self.cmd, arglist, verifylist)
@@ -1622,6 +1622,7 @@ class TestImageSave(TestImage):
self.client.download_image.assert_called_once_with(
self.image.id,
+ stream=True,
output='/path/to/file')