Skip to content

Commit

Permalink
Merge pull request #839 from openfisca/hush-coverage
Browse files Browse the repository at this point in the history
Restrict some Pytest options to 'make test', not all Pytest runs
  • Loading branch information
Morendil authored Mar 15, 2019
2 parents 9de5f4e + 6c3c624 commit 49053ee
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:

- run:
name: Run Core tests
command: make test
command: env PYTEST_ADDOPTS="--exitfirst" make test

- persist_to_workspace:
root: .
Expand Down
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
# Changelog

### 27.0.1 [#839](https://github.com/openfisca/openfisca-core/pull/839)

#### Technical changes

- Provide three levels of information when running tests depending on context:
- when running `pytest`, all failures are reported, coverage is omitted
- when running `make test`, all failures are reported, with coverage also reported
- in continuous integration, exit on first failure, but report coverage always

# 27.0.0 [#826](https://github.com/openfisca/openfisca-core/pull/826)

#### Breaking changes
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ format-style:
autopep8 `git ls-files | grep "\.py$$"`

test: clean check-syntax-errors check-style
pytest
env PYTEST_ADDOPTS="$$PYTEST_ADDOPTS --cov=openfisca_core" pytest

api:
openfisca serve --country-package openfisca_country_template --extensions openfisca_extension_template
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ exe = true
with-doctest = true

[tool:pytest]
addopts = --showlocals --exitfirst --doctest-modules --disable-pytest-warnings --cov=openfisca_core
addopts = --showlocals --doctest-modules --disable-pytest-warnings
testpaths = tests
python_files = **/*.py
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@

setup(
name = 'OpenFisca-Core',
version = '27.0.0',
version = '27.0.1',
author = 'OpenFisca Team',
author_email = 'contact@openfisca.org',
classifiers = [
Expand Down

0 comments on commit 49053ee

Please sign in to comment.