feat/openapi-3-1-support #221
Workflow file for this run
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: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| workflow_dispatch: | |
| jobs: | |
| tests: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| python-version: ['3.9', '3.10', '3.11', '3.12', '3.13'] | |
| fail-fast: false | |
| steps: | |
| - name: π₯ Checkout code | |
| uses: actions/checkout@v3 | |
| - name: π Setup Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v3 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| architecture: x64 | |
| - name: π¦ Install Poetry and dependencies | |
| run: | | |
| pip install poetry==1.3.1 | |
| poetry install | |
| - name: π Run tests with coverage | |
| run: poetry run pytest --cov=src/ --cov-report=xml --cov-fail-under 90 --cov-config=.coveragerc | |
| - name: π Type checking with ty | |
| run: poetry run ty check src/ | |
| - name: π¨ Code formatting with black | |
| run: poetry run black --check . | |
| - name: π§ Linting | |
| run: poetry run ruff check . | |
| - name: π Upload coverage to Codecov | |
| uses: codecov/codecov-action@v2 | |
| if: always() | |
| with: | |
| token: ${{ secrets.CODECOV_TOKEN }} | |
| directory: ./coverage/reports/ | |
| env_vars: OS,PYTHON | |
| fail_ci_if_error: true | |
| files: ./coverage.xml | |
| flags: unittests | |
| name: codecov-umbrella-${{ matrix.python-version }} | |
| path_to_write_report: .codecov_report.${{ matrix.python-version }}.txt | |
| verbose: true |