Permalink
Browse files

more explicit docker error name

  • Loading branch information...
tjamet committed Jun 10, 2016
1 parent d13d704 commit 0b588721166cd47c16bf2f90a9ad97f523419215
Showing with 3 additions and 2 deletions.
  1. +3 −2 tests/integration/test_main.py
@@ -13,11 +13,12 @@
from caduc.cmd import create_watcher
from .. import mock
e = None
docker_error = None
no_docker = False
try:
docker.Client(**docker.utils.kwargs_from_env(assert_hostname=False)).version()
except Exception as e:
docker_error = e
no_docker = True
@@ -41,7 +42,7 @@ def _trigger(self):
def __str__(self):
return "<Timer: delay: %s started: %s>" % (self.delay, self.started)
@unittest.skipIf(no_docker, "Failed to connect to docker host, error: %s" % e)
@unittest.skipIf(no_docker, "Failed to connect to docker host, error: %s" % docker_error)
class IntegrationTest(unittest.TestCase):
def setUp(self):
self.logger = logging.getLogger(type(self).__name__)

0 comments on commit 0b58872

Please sign in to comment.