Add profiling #67
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: test-bench | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| branches: | |
| - main | |
| jobs: | |
| test-bench-matrix-job: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"] | |
| include: | |
| - python-version: 3.8 | |
| allow-failure: false | |
| - python-version: 3.9 | |
| allow-failure: false | |
| - python-version: 3.10 | |
| allow-failure: false | |
| - python-version: 3.11 | |
| allow-failure: false | |
| - python-version: 3.12 | |
| allow-failure: false | |
| - python-version: 3.13 | |
| allow-failure: false | |
| continue-on-error: ${{ matrix.allow-failure }} | |
| name: Python ${{ matrix.python-version }} bench tests | |
| steps: | |
| - name: Check out repository code | |
| uses: actions/checkout@v4 | |
| - name: Cache pip | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.cache/pip | |
| key: ${{ runner.os }}-pip-${{ hashFiles('pyproject.toml') }} | |
| restore-keys: | | |
| ${{ runner.os }}-pip- | |
| - name: Install Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install -e .[dev] | |
| - name: Run benchmarks | |
| run: | | |
| python -m unittest discover -s tests -p 'test_bench_*.py' | |
| test-bench-job: | |
| needs: test-bench-matrix-job | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: test-bench-job | |
| run: echo "All bench tests passed." |