redeploy docs after version bump #43
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: Lint & Test | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.11" | |
| - name: Install Linters | |
| run: | | |
| pip install -U pip | |
| pip install "ruff>=0.1.4" "pre-commit>=3.3.3" | |
| - name: Run Linters | |
| run: | | |
| ruff check . --diff | |
| ruff format . --diff | |
| pre-commit run --all-files | |
| test: | |
| env: | |
| USING_COVERAGE: "3.11" | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.10", "3.11", "3.12", "3.13"] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install project | |
| run: | | |
| pip install -U pip | |
| pip install .[dev] | |
| - name: Run tests | |
| run: pytest --mpl --verbose --mpl-generate-summary=html --mpl-results-path=./results | |
| - uses: actions/upload-artifact@v4 | |
| if: failure() | |
| with: | |
| name: pytest-mpl-results-${{ matrix.python-version }} | |
| path: ./results | |
| - name: Run coverage | |
| if: contains(env.USING_COVERAGE, matrix.python-version) | |
| run: | | |
| pytest --cov --verbose | |
| coverage report -mi | |
| coverage xml | |
| - name: Upload coverage to Codecov | |
| if: contains(env.USING_COVERAGE, matrix.python-version) | |
| uses: codecov/codecov-action@v4 | |
| with: | |
| token: ${{ secrets.CODECOV_TOKEN }} | |
| fail_ci_if_error: true |