Skip to content

Commit

Permalink
Catch all cases of missing pytest (#2568)
Browse files Browse the repository at this point in the history
Command `pytest` is not available on distributions such as Ubuntu 22.04,
where only `pytest-3`/`py.test-3` are available.
  • Loading branch information
DimitriPapadopoulos authored Oct 31, 2022

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
1 parent 41c9668 commit 73d0497
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -54,7 +54,12 @@ flake8:
flake8

pytest:
pytest codespell_lib
@if command -v pytest > /dev/null; then \
pytest codespell_lib; \
else \
echo "Test dependencies not present, install using 'pip install -e \".[dev]\"'"; \
exit 1; \
fi

clean:
rm -rf codespell.1

0 comments on commit 73d0497

Please sign in to comment.