From f0a55936f513b7e1b1022207e2d9206d9c261ca6 Mon Sep 17 00:00:00 2001 From: Joe Talbott Date: Thu, 5 Feb 2015 11:20:28 -0500 Subject: [PATCH] boottest - Add exception message to warning print and fix typo --- boottest.py | 4 ++-- tests/test_boottest.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/boottest.py b/boottest.py index 174001c..2f72e9e 100644 --- a/boottest.py +++ b/boottest.py @@ -82,8 +82,8 @@ class TouchManifest(object): try: response = urllib.urlopen(url) except IOError as e: - print("W: [%s] - error connecting to %s" % ( - time.asctime(), self.path)) + print("W: [%s] - error connecting to %s: %s" % ( + time.asctime(), self.path, e)) return success # failure # Only [re]create the manifest file if one was successfully downloaded diff --git a/tests/test_boottest.py b/tests/test_boottest.py index 1f7acfb..03d0ece 100644 --- a/tests/test_boottest.py +++ b/tests/test_boottest.py @@ -89,7 +89,7 @@ class TestTouchManifest(unittest.TestCase): self.assertEqual(1, len(manifest._manifest)) self.assertIn('foo', manifest) - def test_fetch_excpetion(self): + def test_fetch_exception(self): _p = mock.patch('urllib.urlopen') mocked_urlopen = _p.start() self.addCleanup(_p.stop)