Message140999
Having a "TestCase factory" would be pretty easy, and solve the scaling problems.
For example:
def make_testcase_classes():
for backend in backends:
yield type(
'{}Test'.format(backend.name),
(TheBaseClass, unittest.TestCase),
{'backend': backend}
)
You would use this in the load_tests function at the module level to generate all the test cases. |
|
Date |
User |
Action |
Args |
2011-07-23 18:10:00 | michael.foord | set | recipients:
+ michael.foord, terry.reedy, exarkun, ncoghlan, pitrou, ezio.melotti, eric.araujo, r.david.murray, brian.curtin, fperez, Yaroslav.Halchenko, nchauvat, abingham, eric.snow |
2011-07-23 18:10:00 | michael.foord | set | messageid: <1311444600.74.0.197958818172.issue12600@psf.upfronthosting.co.za> |
2011-07-23 18:10:00 | michael.foord | link | issue12600 messages |
2011-07-23 18:10:00 | michael.foord | create | |
|