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

TST: add github test action #3

Merged
merged 6 commits into from
Aug 17, 2022
Merged

TST: add github test action #3

merged 6 commits into from
Aug 17, 2022

Conversation

hagenw
Copy link
Member

@hagenw hagenw commented Aug 16, 2022

This adds a definition file for executing tests on github (so called github Actions).
It updates the pytest settings in setup.cfg to store the coverage report as a XML file, that is then uploaded in the Action to codecov.io which we can then use in other pull request to report if the code coverage has changed.
It also limits the installed flake8 version as the newly released 5.0.0 version does no longer work with the current latest pytest version.

Tests are added for:

  • Ubuntu, Python 3.7, 3.8, 3.9
  • Windows, Python 3.8
  • MacOS, Python 3.8
  • Ubuntu and building docs, Python 3.8

@hagenw hagenw requested a review from sandneurodata August 16, 2022 12:04
Copy link
Contributor

@sandneurodata sandneurodata left a comment

Choose a reason for hiding this comment

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

all good to me . Just a quick question regarding audb : why did you change it from a global import to an import within a function in test_audeering_internal?

@hagenw
Copy link
Member Author

hagenw commented Aug 17, 2022

For whatever reason pytest executes all imports in the files starting with test_ inside the tests/ folder, including test_audeering_internal.py and ignore that this file is not marked to be executed.
In order to not have to install audb for the tests, I solved this problem by moving the import inside the function.
Maybe we can get rid of it altogether by removing test_audeering_internal.py altogether, see #2.

@hagenw hagenw merged commit 1462003 into master Aug 17, 2022
@hagenw hagenw deleted the add-tests branch August 17, 2022 08:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants