Update Submodule and Run Tests #1
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: Update Submodule and Run Tests | |
| on: | |
| schedule: | |
| - cron: '0 11 * * 4' # Runs weekly on Thursday at 11 am | |
| workflow_dispatch: | |
| env: | |
| PY_COLORS: 1 | |
| PYTEST_ADDOPTS: "--numprocesses=logical" | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| pytest: | |
| strategy: | |
| matrix: | |
| python-version: ["3.12"] | |
| os: [ubuntu-latest] | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: "true" | |
| cache-suffix: pytest-${{ matrix.python-version }} | |
| cache-dependency-glob: "pyproject.toml" | |
| - name: install-reqs | |
| run: | | |
| git submodule update --init --recursive | |
| uv pip install -e narwhals --system | |
| uv pip install -e . --group tests --system | |
| - name: run-submodule-update | |
| run: . utils/submodule_update.sh | |
| - name: update-tests | |
| run: python update_run_tests.py | |
| - name: create-pull-request | |
| uses: peter-evans/create-pull-request@v8 | |
| with: | |
| commit-message: 'chore: auto-update tests and submodule' | |
| title: 'chore: auto-update tests and submodule' | |
| branch: chore/test-and-submodule-auto-updates | |
| delete-branch: true |