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

Make instructions on how to run tests explicit #33

Closed
csadorf opened this issue Jul 19, 2022 · 0 comments · Fixed by #34
Closed

Make instructions on how to run tests explicit #33

csadorf opened this issue Jul 19, 2022 · 0 comments · Fixed by #34

Comments

@csadorf
Copy link

csadorf commented Jul 19, 2022

This issue was created in response to this comment as part of the JOSS paper review.

#31 tries to improve the documentation of the tests.

Unfortunately the instructions remain ambiguous. Instructions on how to run tests should be as unambiguous and explicit as possible. I will explain what I mean by quoting from the improved instructions:


When installing the repository using poetry, all dev dependencies are installed by default.

Instructions on how to install via poetry only come later and include the --no-dev option – meaning that test dependencies are in fact not installed unless one infers that this option must be dropped.

When using pip for installation make sure to install the two dev dependencies pytest and ipytest, with the versions listed in pyproject.toml, manually:

pip install pytest
pip install ipytest

The instructions and the shown commands contradict each other since the latter will always install the latest version of the respective packages. Further, a version for pytest is not listed in the pyproject.toml file.


It is ok to be opinionated about how tests are supposed to be run for your package. If creating the correct environment is easier done using poetry then simply make that the recommended path, you can always provide instructions for alternative paths that can then be slightly less explicit. Here is my take at the instructions:

To run tests:

  1. Install poetry
  2. Create the test environment with $ poetry install
  3. Run tests by executing $ nbdev_test_nbs
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 a pull request may close this issue.

1 participant