News and announcements

0.0.3 released

Written for Testrepository by Robert Collins on 2010-02-28

I'm very happy to released testrepository 0.0.3. This adds the 'testr run' workflow, which permits a tight loop around test failures, with testr tracking the failures, while still allowing you to run only some tests - and can by default run only the failing tests.

See the documentation for details, but as a teaser:
# I break a test test
$ testr run test_selftest
running: ./bzr selftest --subunit test_selftest| testr load
FAIL: bzrlib.tests.test_selftest.TestRunSuite.test_runner_class
Text attachment: log
10.832 encoding stdout as sys.stdin encoding 'UTF-8'
Text attachment: traceback
Traceback (most recent call last):
  File "/usr/lib/python2.6/dist-packages/testtools/", line 128, in _run_user
    return fn(*args)
  File "/usr/lib/python2.6/dist-packages/testtools/", line 368, in _run_test_method
  File "/home/robertc/source/baz/pending/working/bzrlib/tests/", line 2969, in test_runner_class
    self.assertLength(2, calls)
AssertionError: Incorrect length: wanted 2, got 1 for [<bzrlib.tests.CountingDecorator tests=[<bzrlib.tests.test_selftest.Stub.test_foo id=0x6732e10>]>]
id: 15 tests: 203 failures: 1
# Remind me of the failures
$ testr failing
FAIL: bzrlib.tests.test_selftest.TestRunSuite.test_runner_class
[<bzrlib.tests.test_selftest.Stub.test_foo id=0x6732e10>]>]
# I fixed it
$ testr run --failing
running: ./bzr selftest --subunit --load-list /home/robertc/source/baz/pending/working/failing.list| testr load
id: 16 tests: 1

11 of 1 result