[CMF-checkins] CVS: CMF - test_all.py:1.2
tseaver@digicool.com
tseaver@digicool.com
Sat, 2 Jun 2001 00:19:53 -0400 (EDT)
Update of /cvs-repository/CMF/CMFTopic/tests
In directory korak.digicool.com:/tmp/cvs-serv28882/CMFTopic/tests
Modified Files:
test_all.py
Log Message:
- Clean up the 'test_all' architecture:
o use JUnitTextTestRunner;
o implement 'test_suite' protocol, to permit federation by a
smarter test builder.
--- Updated File test_all.py in package CMF --
--- test_all.py 2001/05/07 14:43:43 1.1
+++ test_all.py 2001/06/02 04:19:52 1.2
@@ -1,17 +1,21 @@
import unittest
-from Products.CMFTopic.tests import test_Topic, test_DateC, test_ListC, \
- test_SIC, test_SSC
+from Products.CMFTopic.tests import test_Topic
+from Products.CMFTopic.tests import test_DateC
+from Products.CMFTopic.tests import test_ListC
+from Products.CMFTopic.tests import test_SIC
+from Products.CMFTopic.tests import test_SSC
-def main():
- suite = unittest.TestSuite((
- test_Topic.test_suite(),
- test_DateC.test_suite(),
- test_ListC.test_suite(),
- test_SIC.test_suite(),
- test_SSC.test_suite(),
- ))
- unittest.TextTestRunner().run(suite)
+def test_suite():
+ suite = unittest.TestSuite()
+ suite.addTest( test_Topic.test_suite() )
+ suite.addTest( test_DateC.test_suite() )
+ suite.addTest( test_ListC.test_suite() )
+ suite.addTest( test_SIC.test_suite() )
+ suite.addTest( test_SSC.test_suite() )
+ return suite
+def run():
+ unittest.JUnitTextTestRunner().run(test_suite())
+
if __name__ == '__main__':
- main()
-
+ run()