Merge branch 'develop' of https://github.com/saltstack/salt into develop

This commit is contained in:
Larry Price 2012-06-30 11:43:49 -07:00
commit 77f54af75e
2 changed files with 8 additions and 4 deletions

View File

@ -5,15 +5,20 @@ Test the django module
import sys
# Import Salt libs
from saltunittest import TestLoader, TextTestRunner
from saltunittest import TestLoader, TextTestRunner, skipIf
import integration
from integration import TestDaemon
from salt.modules import django
django.__salt__ = {}
from mock import MagicMock, patch
try:
from mock import MagicMock, patch
has_mock = True
except ImportError:
has_mock = False
@skipIf(has_mock is False, "mock python module is unavailable")
class DjangoModuleTest(integration.ModuleCase):
'''
Test the django module

View File

@ -18,8 +18,7 @@ if sys.version_info[0:2] < (2, 7):
TestCase, expectedFailure, \
TestSuite, skipIf
except ImportError:
print("You need to install unittest2 to run the salt tests")
sys.exit(1)
raise SystemExit("You need to install unittest2 to run the salt tests")
else:
from unittest import TestLoader, TextTestRunner,\
TestCase, expectedFailure, \