[Zope3-checkins] CVS: Zope3 - test.py:1.89
Jeremy Hylton
jeremy at zope.com
Tue Mar 16 00:15:16 EST 2004
Update of /cvs-repository/Zope3
In directory cvs.zope.org:/tmp/cvs-serv27540
Modified Files:
test.py
Log Message:
Simplify.
Uniform handling of errors in get_suite() allows this code to be
simplified.
=== Zope3/test.py 1.88 => 1.89 ===
--- Zope3/test.py:1.88 Tue Mar 16 00:11:02 2004
+++ Zope3/test.py Tue Mar 16 00:15:16 2004
@@ -575,16 +575,7 @@
modname = finder.module_from_path(file)
try:
mod = package_import(modname)
- except ImportError, err:
- result.addError(PseudoTestCase(modname), sys.exc_info())
- return None
- try:
- suite_func = mod.test_suite
- except AttributeError:
- result.addError(PseudoTestCase(modname), sys.exc_info())
- return None
- try:
- return suite_func()
+ return mod.test_suite()
except:
result.addError(PseudoTestCase(modname), sys.exc_info())
return None
More information about the Zope3-Checkins
mailing list