This repository was archived by the owner on May 22, 2026. It is now read-only.
Repository navigation
Lab18 Complete #99
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: Python CI | |
| on: | |
| push: | |
| paths: | |
| - app_python/** | |
| - .github/actions/python-setup/** | |
| - .github/workflows/python-ci.yml | |
| pull_request: | |
| branches: | |
| - master | |
| paths: | |
| - app_python/** | |
| - .github/actions/python-setup/** | |
| - .github/workflows/python-ci.yml | |
| jobs: | |
| test: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: [3.14] | |
| uv-version: [0.9.30] | |
| os: [ubuntu-latest] | |
| runs-on: ${{ matrix.os }} | |
| defaults: | |
| run: | |
| working-directory: ./app_python | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Setup Python tooling and dependencies | |
| uses: ./.github/actions/python-setup | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| uv-version: ${{ matrix.uv-version }} | |
| working-directory: app_python | |
| lockfile-path: app_python/uv.lock | |
| install-args: --frozen | |
| - name: Lint with flake8 | |
| run: uv run flake8 src tests | |
| - name: Test using pytest with coverage report | |
| run: | | |
| mkdir -p test-results | |
| uv run pytest \ | |
| --junitxml=test-results/pytest-report.xml \ | |
| --cov=src \ | |
| --cov-report=term-missing \ | |
| --cov-report=xml:test-results/coverage.xml | |
| - name: Upload pytest and coverage reports | |
| if: always() | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: python-test-reports | |
| path: | | |
| app_python/test-results/pytest-report.xml | |
| app_python/test-results/coverage.xml |