Re: unit tests in a sorry state

Andreas Jung <[email protected]>
Newsgroups gmane.comp.web.zope.coders
Message-ID <71ED5436CF450ADBAC139240@[192.168.0.100]>
I tried Python 2.3.5c1 with the latest 2.7 checkout on FC3 and all tests 
pass.

-aj

--On Mittwoch, 2. Februar 2005 23:38 Uhr +1100 Anthony Baxter 
<[email protected]> wrote:

> There's a number of parts to this email, all of which relate to my
> attempts to run Zope2 unit tests under Python 2.3.5c1
>
> These are all with Python 2.3.5c1, built with
> gcc version 3.4.3 20050113 (Red Hat 3.4.3-14)
> on a Fedora Core box with kernel  2.6.8-1.541
> and glibc version 2.3.3-87.
>
> Running Zope 2.7.4's tests under Python 2.3.5c1 has a bunch of
> errors, most of which appear to be timezone related.
>
> ======================================================================
> FAIL: Precision of serial additions
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/Zope-2.7.4-0/lib/python/DateTime/tests/testD
> ateTime.py",  line 61, in testAddPrecision
>     dt)
>   File "/usr/local/lib/python2.3/unittest.py", line 302, in
> failUnlessEqual     raise self.failureException, \
> AssertionError: 2005/02/02 22:54:42.231 US/Eastern
>
> ======================================================================
> FAIL: Constructor from time float and timezone
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/Zope-2.7.4-0/lib/python/DateTime/tests/testD
> ateTime.py",  line 89, in testConstructor5
>     self.assertEqual(str(dt), str(dt1), (dt, dt1))
>   File "/usr/local/lib/python2.3/unittest.py", line 302, in
> failUnlessEqual     raise self.failureException, \
> AssertionError: (DateTime('2005/02/02 22:54:42.270 US/Eastern'),
> DateTime('2005/02/02 06:54:42.270 US/Eastern'))
>
> ======================================================================
> FAIL: rfc822 conversion
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/Zope-2.7.4-0/lib/python/DateTime/tests/testD
> ateTime.py",  line 328, in testRFC822
>     self.assertEqual(dts[5], "%+03d%02d" % divmod( (-offset/60), 60) )
>   File "/usr/local/lib/python2.3/unittest.py", line 302, in
> failUnlessEqual     raise self.failureException, \
> AssertionError: '-0500' != '+1100'
>
> ======================================================================
> FAIL: Reconstruction of a DateTime from its parts, with subtraction
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/Zope-2.7.4-0/lib/python/DateTime/tests/testD
> ateTime.py",  line 138, in testSubtraction
>     self.assertEqual(dt1, dt3, (dt, dt1, dt2, dt3))
>   File "/usr/local/lib/python2.3/unittest.py", line 302, in
> failUnlessEqual     raise self.failureException, \
> AssertionError: (DateTime('2005/02/02 22:55:01.852 US/Eastern'),
> DateTime('2005/01/30 03:31:08.247 US/Eastern'), DateTime('2005/02/02
> 22:55:01.852 US/Eastern'), DateTime('2005/01/30 19:31:08.247 US/Eastern'))
>
> ======================================================================
> FAIL: check7ZODBThreads (ZODB.tests.testFileStorage.FileStorageTests)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/Zope-2.7.4-0/lib/python/ZODB/tests/MTStorage
> .py",  line 217, in check7ZODBThreads
>     self._checkNThreads(7, ZODBClientThread, db, self)
>   File
> "/home/anthony/projects/zope/Zope-2.7.4-0/lib/python/ZODB/tests/MTStorage
> .py",  line 206, in _checkNThreads
>     t.join(60)
>   File
> "/home/anthony/projects/zope/Zope-2.7.4-0/lib/python/ZODB/tests/MTStorage
> .py",  line 41, in run
>     self.runtest()
>   File
> "/home/anthony/projects/zope/Zope-2.7.4-0/lib/python/ZODB/tests/MTStorage
> .py",  line 70, in runtest
>     self.test.fail()
>   File "/usr/local/lib/python2.3/unittest.py", line 270, in fail
>     raise self.failureException, msg
> AssertionError
>
> ----------------------------------------------------------------------
> Ran 2369 tests in 218.883s
>
> FAILED (failures=5)
>
> In addition, we have this warning on a box with PIE, and a Python
> running in the top half of the address space:
>
> /home/anthony/projects/zope/Zope-2.7.4-0/lib/python/BTrees/check.py:207:
> FutureWarning: %u/%o/%x/%X of negative int will return a signed string in
> Python 2.4 and up
>   return "%s (0x%x)" % (type(obj).__name__, id(obj))
> Script (Python):filepath:1: DeprecationWarning: integer argument
> expected, got  float
> /home/anthony/projects/zope/Zope-2.7.4-0/lib/python/ZODB/Connection.py:15
> 2:  FutureWarning: %u/%o/%x/%X of negative int will return a signed
> string in  Python 2.4 and up
>   return '<Connection at %08x%s>' % (id(self), ver)
> /home/anthony/projects/zope/Zope-2.7.4-0/lib/python/ZODB/tests/testTransa
> ction.py:599:  FutureWarning: %u/%o/%x/%X of negative int will return a
> signed string in  Python 2.4 and up
>   return "<jar %X %s>" % (id(self), self.errors)
>
> Under svn trunk of Zope2, I get the following error:
> Traceback (most recent call last):
>   File "./test.py", line 920, in ?
>     process_args()
> [...snip...]
>   File
> "/home/anthony/projects/zope/svntrunk/lib/python/Products/PluginIndexes/c
> ommon/UnIndex.py",  line 91
>     except:
>           ^
> IndentationError: unindent does not match any outer indentation level
>
> This is a trivial error - I don't have write access to the repository any
> more, so I can't fix it. add one space to that line.
>
> Running the tests after this killed my machine after something gobbled up
> hundreds of megabytes of virtual memory. After a reboot, I set a ulimit
> on  memorysize to 250MB, I got one breakage, and a bunch of failures (also
> timezone related). There were probably other problems after this test
> aborted, but I'm not inclined to mess about with it.
>
> ======================================================================
> ERROR: testSerialization (ZEO.tests.test_cache.CacheTests)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/svntrunk/lib/python/ZEO/tests/test_cache.py"
> ,  line 138, in testSerialization
>     dst.write(src.read(self.cache.fc.maxsize))
> MemoryError
>
> ======================================================================
> FAIL: Precision of serial additions
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/svntrunk/lib/python/DateTime/tests/testDateT
> ime.py",  line 61, in testAddPrecision
>     dt)
>   File "/usr/local/lib/python2.3/unittest.py", line 302, in
> failUnlessEqual     raise self.failureException, \
> AssertionError: 2005/02/02 23:22:14.397 US/Eastern
>
> ======================================================================
> FAIL: Constructor from time float and timezone
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/svntrunk/lib/python/DateTime/tests/testDateT
> ime.py",  line 89, in testConstructor5
>     self.assertEqual(str(dt), str(dt1), (dt, dt1))
>   File "/usr/local/lib/python2.3/unittest.py", line 302, in
> failUnlessEqual     raise self.failureException, \
> AssertionError: (DateTime('2005/02/02 23:22:14.400 US/Eastern'),
> DateTime('2005/02/02 07:22:14.400 US/Eastern'))
>
> ======================================================================
> FAIL: rfc822 conversion
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/svntrunk/lib/python/DateTime/tests/testDateT
> ime.py",  line 322, in testRFC822
>     self.assertEqual(dts[5], "%+03d%02d" % divmod( (-offset/60), 60) )
>   File "/usr/local/lib/python2.3/unittest.py", line 302, in
> failUnlessEqual     raise self.failureException, \
> AssertionError: '-0500' != '+1100'
>
> ======================================================================
> FAIL: Reconstruction of a DateTime from its parts, with subtraction
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
> "/home/anthony/projects/zope/svntrunk/lib/python/DateTime/tests/testDateT
> ime.py",  line 138, in testSubtraction
>     self.assertEqual(dt1, dt3, (dt, dt1, dt2, dt3))
>   File "/usr/local/lib/python2.3/unittest.py", line 302, in
> failUnlessEqual     raise self.failureException, \
> AssertionError: (DateTime('2005/02/02 23:22:29.181 US/Eastern'),
> DateTime('2005/01/30 03:58:35.576 US/Eastern'), DateTime('2005/02/02
> 23:22:29.181 US/Eastern'), DateTime('2005/01/30 19:58:35.576 US/Eastern'))
>
> ----------------------------------------------------------------------
> Ran 2713 tests in 281.299s
>
> FAILED (failures=4, errors=1)
>
>
>
> --
> Anthony Baxter     <[email protected]>
> It's never too late to have a happy childhood.
> _______________________________________________
> Zope-Coders mailing list
> [email protected]
> http://mail.zope.org/mailman/listinfo/zope-coders
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.