Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci(tox): fix collecting code coverage information #727

Merged
merged 1 commit into from
Aug 26, 2024

Conversation

tiborsimko
Copy link
Member

Fixes tox configuration with respect to installing all optional package dependencies that are necessary for running various tests.

Fixes tox collecting of code coverage information by forcing editable mode also in the test running instructions.

tiborsimko added a commit to tiborsimko/reana-client that referenced this pull request Aug 22, 2024
Fixes `tox` configuration with respect to installing all optional
package dependencies that are necessary for running various tests.

Fixes `tox` collecting of code coverage information by forcing editable
mode also in the test running instructions.
py39
py310
py311
py312
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: for Python 3.12, to run tox -e py312 locally, we need to first release new pytest-reana that is bumping the limit of the coverage dependency. This is done in reanahub/pytest-reana#134

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$ sudo dnf install python3.8 python3.9 python3.10 python3.11 python3.12
$ sudo dnf install python3.10-devel python3.11-devel python3.12-devel
$ tox --skip-env py312
...
  py38: OK (43.40=setup[14.36]+cmd[11.09,17.95] seconds)
  py39: OK (55.55=setup[21.52]+cmd[16.22,17.80] seconds)
  py310: OK (54.54=setup[20.63]+cmd[15.61,18.31] seconds)
  py311: OK (73.71=setup[1.25]+cmd[5.53,66.94] seconds)
  congratulations :) (227.31 seconds)

@tiborsimko tiborsimko self-assigned this Aug 22, 2024
tox.ini Outdated
pytest
pytest-cov
commands =
pip install -e .[all]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shall we use extras instead of manually installing the packages in commands? https://tox.wiki/en/latest/config.html#extras

Fixes `tox` configuration with respect to installing all optional
package dependencies that are necessary for running various tests.

Fixes `tox` collecting of code coverage information by forcing editable
mode when running tests.
@tiborsimko tiborsimko merged commit cd45ad5 into reanahub:master Aug 26, 2024
23 checks passed
@tiborsimko tiborsimko deleted the tox-coverage branch August 26, 2024 15:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants