diff options
author | hongbo tian <hongbo.tianhongbo@huawei.com> | 2017-03-30 07:45:13 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2017-03-30 07:45:13 +0000 |
commit | aa8654d4f3f727f99016aaa540c8d5aa3f79edcb (patch) | |
tree | 01a0945c4ee00eb88472c03e3132deb2d35cba49 /dovetail/test_runner.py | |
parent | 7063707c6d95db5dc0b48f6527768d411ff5ecf6 (diff) | |
parent | ce896972a0b263e1d83b61f071e5ccbb945c8696 (diff) |
Merge "dovetail tool: change function pull_image"
Diffstat (limited to 'dovetail/test_runner.py')
-rw-r--r-- | dovetail/test_runner.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/dovetail/test_runner.py b/dovetail/test_runner.py index a67a6314..32a18743 100644 --- a/dovetail/test_runner.py +++ b/dovetail/test_runner.py @@ -35,10 +35,11 @@ class DockerRunner(object): self.logger.error('%s image not exist offline running', self.testcase.validate_type()) return - container_id = Container.create(self.testcase.validate_type()) else: - Container.pull_image(self.testcase.validate_type()) - container_id = Container.create(self.testcase.validate_type()) + if not Container.pull_image(self.testcase.validate_type()): + self.logger.error("Failed to pull the image.") + return + container_id = Container.create(self.testcase.validate_type()) if not container_id: self.logger.error('failed to create container') return |