Attempt to produce better error messages if dependencies aren't met
This commit is contained in:
parent
3fece19638
commit
64e1f081f4
@ -26,7 +26,12 @@ import planet
|
|||||||
planet.getLogger("WARNING")
|
planet.getLogger("WARNING")
|
||||||
|
|
||||||
# load all of the tests into a suite
|
# load all of the tests into a suite
|
||||||
suite = unittest.TestLoader().loadTestsFromNames(modules)
|
try:
|
||||||
|
suite = unittest.TestLoader().loadTestsFromNames(modules)
|
||||||
|
except Exception, exception:
|
||||||
|
# attempt to produce a more specific message
|
||||||
|
for module in modules: __import__(module)
|
||||||
|
raise
|
||||||
|
|
||||||
# run test suite
|
# run test suite
|
||||||
unittest.TextTestRunner().run(suite)
|
unittest.TextTestRunner().run(suite)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user