Re: unittest behaving oddly

2006-06-20 Thread Fredrik Lundh
David Vincent wrote: > The code quoted above was from my verbatim copy of the example from the > doc strings of unittest.py, from my computer's Python library. I > wonder how the example code could have been so badly wrong? self-eating viruses on your machine ? $ more unittest.py ... Simple

Re: unittest behaving oddly

2006-06-20 Thread David Vincent
-BEGIN PGP SIGNED MESSAGE- On 20/06/2006, at 23:15, Mike Kent wrote: > David Vincent wrote: > >>> import unittest >>> >>> class IntegerArithmenticTestCase(unittest.TestCase): >>> def testAdd(self): ## test method names begin 'test*' >>> assertEquals((1 + 2), 3) >>> as

Re: unittest behaving oddly

2006-06-20 Thread Mike Kent
David Vincent wrote: > > import unittest > > > > class IntegerArithmenticTestCase(unittest.TestCase): > > def testAdd(self): ## test method names begin 'test*' > > assertEquals((1 + 2), 3) > > assertEquals(0 + 1, 1) assertEquals is a member function, inherited from unittest.T

unittest behaving oddly

2006-06-20 Thread David Vincent
-BEGIN PGP SIGNED MESSAGE- Hello I'm hoping to get some insight into a situation that seems odd to me. My Python experience is limited; I've just started using the unittest module. I've had some experience with unit test support in other languages. Two computers that I use are sim