From: Steve W. <ste...@gs...> - 2002-05-20 22:31:26
|
Gerhard H=E4ring wrote: > I'm not sure where you got that unittest.py from, but it's apparently > not from pyunit 1.4 (__version__ =3D=3D "1.40"), or Python 2.2.1 > (__version__ =3D=3D "1.14"). Looks like you only need to place the orig= inal > Python 2.2.1 unittest.py (is most recent available) there again. You're right -- I deleted the unittest.py from my site-packages and=20 the one in Python 2.2.1 shows __version__ =3D=3D "1.14" ... now the test=20 script works: -------------------------------------------------------------------- [waterbug@beeblebrox test]$ python PgSQLTestCases.py=20 ............................................F....F. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D FAIL: Test execute() with a singleton string as the parameter. ---------------------------------------------------------------------- Traceback (most recent call last): File "PgSQLTestCases.py", line 494, in CheckExecuteWithSingleton "Length of cur.description is %d, it should be %d." % File "/usr/local/lib/python2.2/unittest.py", line 286, in failUnlessEqu= al raise self.failureException, \ AssertionError: Length of cur.description is 9, it should be 4. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D FAIL: MoreResultObjectChecks (__main__.PgSQLTestCases) ---------------------------------------------------------------------- Traceback (most recent call last): File "PgSQLTestCases.py", line 680, in MoreResultObjectChecks self.fail(msg) File "/usr/local/lib/python2.2/unittest.py", line 254, in fail raise self.failureException, msg AssertionError: invalid syntax (line 1) ---------------------------------------------------------------------- Ran 51 tests in 1.046s FAILED (failures=3D2) ---------------------------------------------------------------------- ... which gives the error you said to expect about the length of=20 cur.description ... whew! =20 Sorry for the false alarm! =20 -- Steve. |