# Test driver for bsddb package.
from test
.test_support
import requires
, verbose
, run_suite
# When running as a script instead of within the regrtest framework, skip the
# requires test, since it's obvious we want to run them.
if __name__
<> '__main__':
if 'verbose' in sys
.argv
:
sys
.argv
.remove('verbose')
if 'silent' in sys
.argv
: # take care of old flag, just in case
sys
.argv
.remove('silent')
alltests
= unittest
.TestSuite()
for name
in test_modules
:
module
= __import__("bsddb.test."+name
, globals(), locals(), name
)
alltests
.addTest(module
.test_suite())
# For invocation through regrtest
# For invocation as a script
if __name__
== '__main__':
print db
.DB_VERSION_STRING
print 'bsddb.db.version(): %s' % (db
.version(),)
print 'bsddb.db.__version__: %s' % db
.__version
__
print 'bsddb.db.cvsid: %s' % db
.cvsid
print 'python version: %s' % sys
.version
unittest
.main(defaultTest
='suite')