Unittest: how to pass information to TestCase classes?
AK
andrei.avk at gmail.com
Tue Oct 26 14:46:52 EDT 2010
Hi, I have a question about unittest: let's say I create a temp dir for
my tests, then use loadTestsFromNames() to load my tests from packages
and modules they're in, then use TextTestRunner.run() to run the tests,
how can I pass information to TestCase instances, e.g. the location of
the temp dir I created?
The dir has to be created just once, before any tests run, and then
multiple packages and multiple modules in them are imported and run.
Thanks! -ak
More information about the Python-list
mailing list