[Patches] [ python-Patches-804212 ] unittest's main don't handle
TestSuite in command line
SourceForge.net
noreply at sourceforge.net
Sat Dec 6 08:25:30 EST 2003
Patches item #804212, was opened at 2003-09-11 08:52
Message generated for change (Comment added) made by purcell
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=804212&group_id=5470
Category: Library (Lib)
Group: Python 2.3
>Status: Pending
Resolution: None
Priority: 5
Submitted By: Miki Tebeka (tebeka)
Assigned to: Steve Purcell (purcell)
Summary: unittest's main don't handle TestSuite in command line
Initial Comment:
When using unittest's "main" it fails if in the command
line a name of TestSuite class is given.
Suppose ts.py is:
----
#!/usr/bin/env python
from unittest import TestCase, makeSuite, main
class T(TestCase):
def test_moo(self):
self.fail()
test_suite = makeSuite(T, "test_")
if __name__ == "__main__":
main()
----
Then running "ts.py test_suite" will fail.
Attached is a patch for unittest.py
Miki
----------------------------------------------------------------------
>Comment By: Steve Purcell (purcell)
Date: 2003-12-06 14:25
Message:
Logged In: YES
user_id=21477
This is fixed in Python and PyUnit CVS, and will be released either with
2.3.3 or 2.4.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=804212&group_id=5470
More information about the Patches
mailing list