Skip to content

Add permissions for 'Build and Publish' step #50

Add permissions for 'Build and Publish' step

Add permissions for 'Build and Publish' step #50

Workflow file for this run

name: Test
on:
workflow_dispatch: {}
push: {}
jobs:
test:
name: Test
runs-on: ubuntu-latest
continue-on-error: true
strategy:
matrix:
python: ["3.10", "3.11", "3.12"]
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install uv
uses: astral-sh/setup-uv@v5
with:
python-version: ${{ matrix.python }}
- name: Templatize
# Templatize the repo before attempting to run tests. (Tests will fail
# otherwise, due to syntax errors.)
# NOTE: Check if the 'templatize' script exists, so that this doesn't
# immediately fail for repos that have already run the script.
run: |
if test -f "templatize"; then
./templatize
fi
- name: Install Package
run: |
uv pip install -e .[test]
- name: Test
run: |
uv run ruff check .
uv run pytest --cov --cov-report term-missing --cov-fail-under 80 tests/
uv run mypy