[Commits] (pje) Scripts to run and/or profile unit tests,
and test suite definitions for
commits at osafoundation.org
commits at osafoundation.org
Wed Feb 2 09:56:36 PST 2005
Commit by: pje
Modified files:
chandler/profile_tests.py None 1.1
chandler/run_tests.py None 1.1
chandler/.cvsignore 1.18 1.19
chandler/application/tests/__init__.py None 1.1
chandler/repository/tests/__init__.py 1.2 1.3
Log message:
Scripts to run and/or profile unit tests, and test suite definitions for
repository.tests and application.tests. Use 'RunPython run_tests.py'
or 'RunPython profile_tests.py' to view the documentation.
ViewCVS links:
http://cvs.osafoundation.org/index.cgi/chandler/profile_tests.py?rev=1.1&content-type=text/vnd.viewcvs-markup
http://cvs.osafoundation.org/index.cgi/chandler/run_tests.py?rev=1.1&content-type=text/vnd.viewcvs-markup
http://cvs.osafoundation.org/index.cgi/chandler/.cvsignore.diff?r1=text&tr1=1.18&r2=text&tr2=1.19
http://cvs.osafoundation.org/index.cgi/chandler/application/tests/__init__.py?rev=1.1&content-type=text/vnd.viewcvs-markup
http://cvs.osafoundation.org/index.cgi/chandler/repository/tests/__init__.py.diff?r1=text&tr1=1.2&r2=text&tr2=1.3
Index: chandler/.cvsignore
diff -u chandler/.cvsignore:1.18 chandler/.cvsignore:1.19
--- chandler/.cvsignore:1.18 Tue Oct 19 11:31:06 2004
+++ chandler/.cvsignore Wed Feb 2 09:56:33 2005
@@ -7,6 +7,7 @@
debug
release
randpool.dat
+profile.dat
*.inst
*.gz
*.md5
Index: chandler/repository/tests/__init__.py
diff -u chandler/repository/tests/__init__.py:1.2 chandler/repository/tests/__init__.py:1.3
--- chandler/repository/tests/__init__.py:1.2 Wed Sep 29 13:04:02 2004
+++ chandler/repository/tests/__init__.py Wed Feb 2 09:56:34 2005
@@ -1,8 +1,33 @@
+"""Repository tests package
-__revision__ = "$Revision: 1.2 $"
-__date__ = "$Date: 2004/09/29 20:04:02 $"
+When adding repository test modules to this package, please add their
+name to the __all__ list, below. Do not add non-test modules, or module
+names outside this package.
+"""
+
+__revision__ = "$Revision: 1.3 $"
+__date__ = "$Date: 2005/02/02 17:56:34 $"
__copyright__ = "Copyright (c) 2003-2004 Open Source Applications Foundation"
__license__ = "http://osafoundation.org/Chandler_0.1_license_terms.htm"
# The tests package
+__all__ = [
+ 'TestAlias', 'TestBZ2', 'TestBinary', 'TestDeepCopyRef', 'TestDelete',
+ 'TestIndexes', 'TestItems', 'TestKinds', 'TestLiteralAttributes',
+ 'TestMerge', 'TestMixins', 'TestMove', 'TestPerfWithRSS',
+ 'TestPersistentCollections', 'TestRedirectToOrdering', 'TestRefDictAlias',
+ 'TestReferenceAttributes', 'TestRepository', 'TestRepositoryBasic',
+ 'TestSkipList', 'TestText', 'TestTypes',
+]
+
+
+def suite():
+ """Unit test suite; run by testing 'repository.tests.suite'"""
+
+ from unittest import defaultTestLoader, TestSuite
+ return TestSuite(
+ [defaultTestLoader.loadTestsFromName(__name__+'.'+test_name)
+ for test_name in __all__]
+ )
+
More information about the Commits
mailing list