Bump actions/checkout from 4.2.0 to 4.2.2 #262
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
env: | |
FORCE_COLOR: "1" # Make tool output pretty. | |
PIP_DISABLE_PIP_VERSION_CHECK: "1" | |
PIP_PROGRESS_BAR: "off" | |
jobs: | |
tests: | |
name: Python ${{ matrix.python-version }} | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: | |
- '3.10' | |
- '3.11' | |
- '3.12' | |
- '3.13' | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 | |
- uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: | | |
python -VV | |
python -m pip install --upgrade pip wheel | |
python -m pip install --upgrade .[tests] | |
- name: Run tests & collect coverage | |
run: | | |
python -m coverage run -p -m pytest | |
- name: Upload coverage data | |
uses: actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 | |
with: | |
include-hidden-files: true | |
name: coverage-data-${{ matrix.python-version }} | |
path: .coverage.* | |
coverage: | |
name: Combine & check coverage | |
needs: tests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 | |
- uses: actions/setup-python@f677139bbe7f9c59b41e40162b753c062f5d49a3 | |
with: | |
python-version: '3.12' | |
- name: Install dependencies | |
run: python -m pip install --upgrade coverage[toml] | |
- name: Download data | |
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 | |
with: | |
pattern: coverage-data-* | |
merge-multiple: true | |
- name: Combine coverage, create reports and fail if less than threshold. | |
run: | | |
python -m coverage combine | |
python -m coverage html --skip-empty | |
echo '## Test Coverage Report' >> $GITHUB_STEP_SUMMARY | |
python -m coverage report --format=markdown >> $GITHUB_STEP_SUMMARY | |
# Merging files from vocexcel in #119 reduced coverage from 100% to 93%. | |
# We are working on getting back to full coverage. | |
python -m coverage report --fail-under=97 | |
- name: Upload HTML report | |
if: ${{ failure() }} | |
uses: actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 | |
with: | |
name: html-report | |
path: .htmlcov |