aboutsummaryrefslogtreecommitdiffstats
path: root/test.py
diff options
context:
space:
mode:
authorW. Trevor King <wking@drexel.edu>2009-11-28 20:27:53 -0500
committerW. Trevor King <wking@drexel.edu>2009-11-28 20:27:53 -0500
commit7e95956f5088346807a233c63f5bc25436550ef8 (patch)
treeefc2576da4b6e3cfd8553ea5c8e737e873476b31 /test.py
parentc90ed61e7deb594edf3707850f2d3a87601a581b (diff)
downloadbugseverywhere-7e95956f5088346807a233c63f5bc25436550ef8.tar.gz
test.py now uses unittest.TestSuite 'suite' in becommands if present.
Such 'suite' instances have been required for libbe submodules. This will allow becommands to test themselves more thoroughly than they could with only doctests.
Diffstat (limited to 'test.py')
-rw-r--r--test.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/test.py b/test.py
index 57091c7..81674cf 100644
--- a/test.py
+++ b/test.py
@@ -27,7 +27,10 @@ if len(sys.argv) > 1:
print "Module \"%s\" has no test suite" % submodname
mod = plugin.get_plugin("becommands", submodname)
if mod is not None:
- suite.addTest(doctest.DocTestSuite(mod))
+ if hasattr(mod, "suite"):
+ suite.addTest(mod.suite)
+ else:
+ suite.addTest(doctest.DocTestSuite(mod))
match = True
if not match:
print "No modules match \"%s\"" % submodname