Tests #1
This file contains hidden or 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: | |
| workflow_run: | |
| workflows: ["Code Quality"] | |
| types: | |
| - completed | |
| jobs: | |
| run_tests_if_successful_build: | |
| if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| python: | |
| - version: "3.10" | |
| image: "python:3.10-slim" | |
| - version: "3.11" | |
| image: "python:3.11-slim" | |
| - version: "3.12" | |
| image: "python:3.12-slim" | |
| container: | |
| image: ${{ matrix.python.image }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Install system dependencies | |
| run: | | |
| apt-get update | |
| apt-get install -y git build-essential | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements-dev.txt | |
| - name: Run tests with coverage | |
| run: | | |
| coverage run -m pytest --maxfail=2 --disable-warnings tests/ | |
| coverage report |