PQM: test failure
Ian Clatworthy
ian.clatworthy at internode.on.net
Mon Apr 2 10:55:54 BST 2007
Olexandr Byelchenko wrote:
> ======================================================================
>
> FAIL: test_known_failure_ok_run (bzrlib.tests.test_selftest.TestRunner)
>
>
>
> vvvv[log from bzrlib.tests.test_selftest.TestRunner.test_known_failure_ok_run]
>
>
>
> ^^^^[log from bzrlib.tests.test_selftest.TestRunner.test_known_failure_ok_run]
>
> ----------------------------------------------------------------------
>
> Traceback (most recent call last):
>
> File "/home/pqm/bzr-pqm-workdir/home/+trunk/bzrlib/tests/test_selftest.py", line 941, in
> test_known_failure_ok_run
>
> stream.getvalue())
>
> File "/home/pqm/bzr-pqm-workdir/home/+trunk/bzrlib/tests/__init__.py", line 798, in assertEqual
>
> raise AssertionError("%snot equal:\na = %s\nb = %s\n"
>
> AssertionError: not equal:
>
> a = '\n----------------------------------------------------------------------\nRan 1 test in
> 0.000s\n\nOK (known_failures=1)\n'
>
> b = '\n----------------------------------------------------------------------\nRan 1 test in
> 0.001s\n\nOK (known_failures=1)\n'
>
>
>
>
>
> ----------------------------------------------------------------------
>
>
> I think it's a very bad style to make test depends on time intervals.
>
> [µ]
>
>
I ran into this one earlier today as well. As a simple "fix", I guess we
could change to an RE match something like 0\.00[012]s for the time
interval. It might still be slower under certain environments though.
Ian C.
More information about the bazaar
mailing list