Update coveragerc files in OpenStack
Currently, the code from Oslo incubator is copied to other projects with a special script. Original Oslo code is highly covered with unit tests, but these tests are not copied with corresponding code. Thus we see incorrect (lower) code coverage statistics. Therefore, Oslo code should be omitted in coverage calculation.
`omit` option for coverage in many projects (glance, keystone, etc.) contains a lot of items that can be eliminated specifying proper `source` option.
So, a typical .coveragerc will be updated from
[run]
branch = True
omit = /usr*,setup.
[report]
ignore-errors = True
to
[run]
branch = True
source = glance
omit = glance/
[report]
ignore-errors = True
With a such config, the true coverage can be calculated with a simple
coverage report
without any extra command line options (e.g., coverage report '--include=
Blueprint information
- Status:
- Complete
- Approver:
- Mark McLoughlin
- Priority:
- Low
- Drafter:
- Alexej Ababilov
- Direction:
- Approved
- Assignee:
- Alexej Ababilov
- Definition:
- Approved
- Series goal:
- Accepted for grizzly
- Implementation:
- Implemented
- Milestone target:
- 2013.1
- Started by
- Mark McLoughlin
- Completed by
- Mark McLoughlin