⬆️ Upgrade ruff version #75
Workflow file for this run
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: tests | |
on: pull_request | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: # Use deploy key to ensure pushed change trigger checks as well : https://github.com/peter-evans/create-pull-request/blob/master/docs/concepts-guidelines.md#workarounds-to-trigger-further-workflow-runs | |
ssh-key: ${{ secrets.SSH_PRIVATE_KEY }} | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.8" | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -e .[test] | |
env: | |
GH_PAT: ${{ secrets.AUTH_TOKEN }} | |
- name: Test with pytest | |
timeout-minutes: 5 | |
run: python -m pytest | |
- name: Check coverage updated | |
run: | | |
prev_cov=$(grep -Po '\d+%' .github/badges/coverage.svg | tail -1 | sed 's/.$//') | |
coverage-badge -o .github/badges/coverage.svg -f | |
curr_cov=$(grep -Po '\d+%' .github/badges/coverage.svg | tail -1 | sed 's/.$//') | |
if [[ "$prev_cov" != "$curr_cov" ]] | |
then | |
echo "Coverage badge is not up-to-date ! Please run the tests ('python -m pytest') and then re-create the badge with 'coverage-badge -o .github/badges/coverage.svg -f'" | |
exit 1 | |
fi |