This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author rbcollins
Recipients
Date 2007-04-23.03:56:38
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
pyunit looks for __unittest = 1 in the globals of functions in an assertion stacktrace. This is used to trim the trace so that unittest implementation methods do  not show up.

It would be great if it looked in the locals of the frame as well, as this would allow subclasses of TestCase that add new assertFOO methods to have them filtered in the same manner.

e.g. (bad example :))
def assertComplexState(self, inputs):
    __unittest = 1
    self.assertEqual('42', inputs[0], 'the input %s is not the right answer' % inputs)

History
Date User Action Args
2007-08-23 16:12:45adminlinkissue1705520 messages
2007-08-23 16:12:45admincreate