github actions: run live tests #45
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: | |
| pull_request: | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: tests-${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| test: | |
| name: Test suite (Python ${{ matrix.python-version }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| # Cover the floor and the latest of the supported range | |
| # (pyproject: requires-python = ">=3.9"). | |
| python-version: ['3.9', '3.11', '3.13'] | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| cache: 'pip' | |
| cache-dependency-path: pyproject.toml | |
| - name: Install package with test extra | |
| run: | | |
| sudo apt update && sudo apt install -yq proot | |
| python -m pip install --upgrade pip | |
| pip install -e '.[test]' | |
| - name: Unit tests | |
| run: python -m pytest tests/unit | |
| - name: Integration tests | |
| run: python -m pytest tests/integration | |
| - name: Security tests | |
| run: python -m pytest tests/security | |
| - name: Live tests | |
| run: RUN_LIVE_TESTS=1 python -m pytest -q tests/live |