cleanup #32
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 | |
| on: | |
| push: | |
| pull_request: | |
| types: [opened, reopened] | |
| jobs: | |
| test-core: | |
| name: Core tests (Python ${{ matrix.python-version }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"] | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Set up Python | |
| uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Set up uv | |
| uses: astral-sh/setup-uv@cec208311dfd045dd5311c1add060b2062131d57 # v8.0.0 | |
| - name: Install dependencies | |
| run: | | |
| uv venv | |
| source .venv/bin/activate | |
| uv lock --check | |
| uv sync --extra dev_core | |
| python --version | |
| - name: Test core | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_core | |
| test-optional: | |
| name: Optional tests (Python ${{ matrix.python-version }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"] | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Set up Python | |
| uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Set up Chrome for Pytest | |
| uses: ./.github/actions/setup-chrome-for-pytest | |
| - name: Set up uv | |
| uses: astral-sh/setup-uv@cec208311dfd045dd5311c1add060b2062131d57 # v8.0.0 | |
| - name: Install dependencies | |
| run: | | |
| uv venv | |
| source .venv/bin/activate | |
| uv sync --extra dev_optional --extra dev_pandas3 | |
| python --version | |
| - name: Test core | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_core | |
| - name: Test optional | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_optional | |
| - name: Test utils | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_plotly_utils/ | |
| - name: Test io | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_io | |
| - name: Test dependencies not imported | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest -x test_init/test_dependencies_not_imported.py | |
| - name: Test lazy imports | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest -x test_init/test_lazy_imports.py | |
| test-optional-legacy-pandas: | |
| name: Optional tests (Python ${{ matrix.python-version }}, pandas ${{ matrix.pandas-version }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - python-version: "3.9" | |
| pandas-version: "1" | |
| - python-version: "3.11" | |
| pandas-version: "2" | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Set up Python | |
| uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Set up Chrome for browser tests | |
| uses: ./.github/actions/setup-chrome-for-pytest | |
| - name: Set up uv | |
| uses: astral-sh/setup-uv@cec208311dfd045dd5311c1add060b2062131d57 # v8.0.0 | |
| - name: Install dependencies | |
| run: | | |
| uv venv | |
| source .venv/bin/activate | |
| uv sync --extra dev_optional --extra dev_pandas${{ matrix.pandas-version }} | |
| - name: Test core | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_core | |
| - name: Test optional | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_optional | |
| - name: Test utils | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_plotly_utils/ | |
| - name: Test io | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_io | |
| - name: Test dependencies not imported | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest -x test_init/test_dependencies_not_imported.py | |
| - name: Test lazy imports | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest -x test_init/test_lazy_imports.py | |
| test-kaleido-v0: | |
| name: Optional tests (Kaleido only), Kaleido v0 (Python 3.12, kaleido 0.2.1) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Set up Python | |
| uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0 | |
| with: | |
| python-version: "3.12" | |
| - name: Set up Chrome | |
| uses: browser-actions/setup-chrome@4f8e94349a351df0f048634f25fec36c3c91eded # v2.1.1 | |
| with: | |
| install-chromedriver: true | |
| - name: Set up uv | |
| uses: astral-sh/setup-uv@cec208311dfd045dd5311c1add060b2062131d57 # v8.0.0 | |
| - name: Install dependencies | |
| run: | | |
| uv venv | |
| source .venv/bin/activate | |
| uv sync --extra dev_optional | |
| uv pip uninstall kaleido | |
| uv pip install kaleido==0.2.1 | |
| python --version | |
| - name: Test plotly.io image output with Kaleido v0 | |
| run: | | |
| source .venv/bin/activate | |
| python -m pytest tests/test_optional/test_kaleido |