summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClaudiu Popa <cpopa@cloudbasesolutions.com>2015-01-28 21:54:38 +0200
committerClaudiu Popa <cpopa@cloudbasesolutions.com>2015-01-28 21:54:38 +0200
commitd33c5a5f05352fd3d0a57779a2fe5c473860df3c (patch)
treeb82779cd7bc518ff22f62fe22df9c60cf7fc2404
parent4edda49f36aefc1e83110a0e860bd098e694d069 (diff)
downloadastroid-git-d33c5a5f05352fd3d0a57779a2fe5c473860df3c.tar.gz
Skip the nose tests if nose is unavailable.
-rw-r--r--astroid/tests/unittest_brain.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/astroid/tests/unittest_brain.py b/astroid/tests/unittest_brain.py
index 39b48844..81cd3595 100644
--- a/astroid/tests/unittest_brain.py
+++ b/astroid/tests/unittest_brain.py
@@ -26,6 +26,13 @@ from astroid import test_utils
import astroid
+try:
+ import nose
+ HAS_NOSE = True
+except ImportError:
+ HAS_NOSE = False
+
+
class HashlibTest(unittest.TestCase):
def test_hashlib(self):
"""Tests that brain extensions for hashlib work."""
@@ -106,6 +113,7 @@ class ModuleExtenderTest(unittest.TestCase):
extender(n)
+@unittest.skipUnless(HAS_NOSE, "This test requires nose library.")
class NoseBrainTest(unittest.TestCase):
def test_nose_tools(self):