Skip to content

Improve documentation how to run tests #851

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

vprivat-ads
Copy link
Contributor

Related Issue(s):

Running only "make test" after a git checkout, like advised in the GitHub pull request template, does not work:

ERROR collecting stac_fastapi/extensions/tests/test_transaction.py __________________________________________________________________________________________
ImportError while importing test module '/home/xxx/projects/stac/stac-fastapi/stac_fastapi/extensions/tests/test_transaction.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib/python3.12/importlib/__init__.py:90: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
stac_fastapi/extensions/tests/test_transaction.py:13: in <module>
    from stac_fastapi.extensions.core.transaction.request import (
E   ModuleNotFoundError: No module named 'stac_fastapi.extensions.core.transaction.request'; 'stac_fastapi.extensions.core.transaction' is not a package

Description:

It is not obvious for newcomers that make install must be called before make test. This PR fixes it in README and GitHub pull request template.

PR Checklist:

  • pre-commit hooks pass locally
  • Tests pass (run make test)
  • Documentation has been updated to reflect changes, if applicable, and docs build successfully (run make docs)
  • Changes are added to the CHANGELOG.

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.

1 participant