diff options
author | Aanand Prasad <aanand.prasad@gmail.com> | 2015-09-21 17:39:48 +0200 |
---|---|---|
committer | Aanand Prasad <aanand.prasad@gmail.com> | 2015-09-22 14:25:28 +0200 |
commit | 3d6c91b46990213b0a7f96005cfc36c5c61e97b7 (patch) | |
tree | 54f6226a776d1e2de23af3c2e2f39fec400c1b06 | |
parent | ef0c373f14982b81786e4918797b41349e55a837 (diff) | |
download | docker-py-3d6c91b46990213b0a7f96005cfc36c5c61e97b7.tar.gz |
Only pull busybox in integration tests if we don't already have it
Signed-off-by: Aanand Prasad <aanand.prasad@gmail.com>
-rw-r--r-- | tests/integration_test.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/integration_test.py b/tests/integration_test.py index bf56ffc..d92500a 100644 --- a/tests/integration_test.py +++ b/tests/integration_test.py @@ -33,7 +33,7 @@ from six.moves import BaseHTTPServer from six.moves import socketserver import docker -from docker.errors import APIError +from docker.errors import APIError, NotFound from docker.utils import kwargs_from_env from .base import requires_api_version @@ -71,7 +71,11 @@ def docker_client_kwargs(**kwargs): def setup_module(): c = docker_client() - c.pull(BUSYBOX) + try: + c.inspect_image(BUSYBOX) + except NotFound: + c.pull(BUSYBOX) + c.inspect_image(BUSYBOX) c.close() |