Run every tools test in CI, with the packages the place and elevation tests need
CI picked tools tests by file name pattern, so test_place_trails.py and nineteen other files never ran there. A new workflow installs the place tool's requirements, numpy and Pillow, runs the place tests and then the whole of tools/tests. The Validate workflow still installs no packages. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
41019c81e1
commit
5d2e26cc85
1 file changed
+26
@@ -0,0 +1,26 @@
|
|||||||
|
name: Tool tests
|
||||||
|
|
||||||
|
# Every test in tools/tests, with the packages some of them need. test_place_trails.py needs the
|
||||||
|
# place tool's requirements (without shapely it skips itself and still passes), and
|
||||||
|
# test_elevation.py needs numpy and Pillow. This is a workflow of its own because the Validate
|
||||||
|
# workflow installs no packages (tools/tests/test_audit_doc.py holds it to that).
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
pull_request:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
tools:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 10
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- uses: actions/setup-python@v5
|
||||||
|
with:
|
||||||
|
python-version: "3.12"
|
||||||
|
cache: pip
|
||||||
|
cache-dependency-path: tools/place_trails.requirements.txt
|
||||||
|
- run: pip install -r tools/place_trails.requirements.txt numpy Pillow
|
||||||
|
- run: python -m unittest discover tools/tests -p "test_place_trails.py"
|
||||||
|
# The whole directory, so that a new test file cannot be left out by a file name pattern.
|
||||||
|
- run: python -m unittest discover tools/tests
|
||||||
Reference in new issue
Block a user