Module Name

Kerim Borchaev warkid at
Wed Aug 15 14:32:31 CEST 2001

Isn't it odd that "reply-to" for messages from this list is not
python-list at

Anyway i'm resending it here :

  Thanks - it worked.
  But what does it mean "module object"?
  When I pass MyModule0Name ( without quotes ) to loadTestsFromModule
  - do I pass "module object" or what?

Best regards,
 Kerim                            mailto:warkid at

Wednesday, August 15, 2001, 2:23:48 PM, you wrote:

>>===== Original Message From "Kerim Borchaev" <warkid at> =====

>>so the question is : How can I implement addModule?

>>def addModule(suite, module):
>>    __import__(module)
>>    suite.addTest(unittest.defaultTestLoader.loadTestsFromModule(module))
>>doesnt execute any test.  loadTestsFromModule doesn't work - and I
>>can't understand why...

HN> I have no experience with unittest, but I think that

HN>   module = __import__(module)

HN> should work. I figure loadTestsFroModule needs a module object, rather than a 
HN> string, which is what it gets now.


HN> --Hans Nowak

More information about the Python-list mailing list