Skip to content

Commit 64eb009

Browse files
authored
Albrja/build utils/mic 7254/turn cov off, enable n auto (#158)
Albrja/build utils/mic 7254/turn cov off Turn on n auto and turn off coverage for test step of CI - *Category*: CI - *JIRA issue*: https://jira.ihme.washington.edu/browse/MIC-7254 Changes and notes -turns --cov off to save runtime -enables n auto from pytest plugin
1 parent 4540017 commit 64eb009

3 files changed

Lines changed: 9 additions & 4 deletions

File tree

libs/build-utils/CHANGELOG.rst

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
1+
**4.2.0 - 06/29/26**
2+
3+
- Run pytest with ``-n auto`` by default to parallelize tests across available workers
4+
- Turn coverage off by default
5+
16
**4.1.0 - 06/29/26**
27

38
- Run mypy in CI based on the presence of a ``py.typed`` marker under ``src/``
4-
- Centralize py.typed marker logic in a new ``mypy-if-typed`` Make target
9+
- Centralize py.typed marker logic in a new ``mypy-if-typed`` Make target
510
- Deprecate the ``run_mypy`` ``reusable_pipeline`` argument; it is still accepted but ignored
611

712
**4.0.2 - 06/24/26**

libs/build-utils/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ dependencies = []
1717
cluster = []
1818
docs = []
1919
interactive = []
20-
test = ["vivarium-dependencies[pytest]"]
20+
test = ["vivarium-dependencies[pytest]", "pytest-xdist"]
2121
lint = ["vivarium-dependencies[lint]"]
2222
dev = ["vivarium-build-utils[docs,interactive,test,lint]"]
2323
ci_github = ["vivarium-build-utils[test,docs,lint]"]

libs/build-utils/resources/makefiles/test.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
define test
22
export COVERAGE_FILE=./output/.coverage.$(1) && \
3-
pytest -vvv $(if $(RUNSLOW),--runslow,) $(if $(RUNWEEKLY),--runweekly,) --cov --cov-report term --cov-report html:./output/htmlcov_$(1) tests/$(1)
3+
pytest -vvv -n auto $(if $(RUNSLOW),--runslow,) $(if $(RUNWEEKLY),--runweekly,) $(if $(COV),--cov --cov-report term --cov-report html:./output/htmlcov_$(1),) tests/$(1)
44
endef
55

66
test-all: # Run all tests
77
export COVERAGE_FILE=./output/.coverage && \
8-
pytest -vvv $(if $(RUNSLOW),--runslow,) $(if $(RUNWEEKLY),--runweekly,) --cov --cov-report term --cov-report html:./output/htmlcov_tests tests/
8+
pytest -vvv -n auto $(if $(RUNSLOW),--runslow,) $(if $(RUNWEEKLY),--runweekly,) $(if $(COV),--cov --cov-report term --cov-report html:./output/htmlcov_tests,) tests/
99

1010
test-e2e: # Run end-to-end tests
1111
$(call test,e2e)

0 commit comments

Comments
 (0)