Improve test.pytest failure when coverage is enabled.

Review Request #3334 - Created Jan. 13, 2016 and submitted

Information
Kris Wilson
pants
kwlzn/pytest_coverage
2800, 2801
Reviewers
pants-reviews
molsen, patricklaw, zundel
  • Avoid an unhandled IOError in shutil.move() during ./pants test.pytest when coverage data files fail to be written due to failures, timeouts, etc.
  • Additive test coverage.

Closes #2800

  • CI is green @ https://travis-ci.org/pantsbuild/pants/builds/102231818

  • manual testing using the repro on #2800:

[illuminati pants (kwlzn/pytest_coverage)]$ ./pants clean-all test.pytest --test-pytest-coverage=1 --timeout-default=1 tests/python/pants_test/java:nailgun_integration
INFO] Detected git repository at /Users/kwilson/dev/pants on branch kwlzn/pytest_coverage

15:40:12 00:00 [main]
...
15:40:14 00:02     [test]
15:40:14 00:02     [pytest]
15:40:14 00:02       [run]

15:40:14 00:02         [chroot]============== test session starts ===============
                     platform darwin -- Python 2.7.10 -- py-1.4.30 -- pytest-2.6.4
                     plugins: timeout
                     collecting 0 itemsWARN] No .coverage file was found! Skipping coverage reporting.
                     collected 1 items

                     tests/python/pants_test/java/test_nailgun_integration.py
FAILURE: Timeout of 1 seconds reached


15:40:15 00:03   [complete]
               FAILURE
Eric Ayers
Kris Wilson
Matt Olsen
Eric Ayers
Kris Wilson
Review request changed

Status: Closed (submitted)

Change Summary:

thanks Eric & Matt! this is in @ 860c33393fc99f3e3594fb1b1fc1bf8fc8f8f68e

Loading...