⬆ Bump actions/upload-artifact from 5 to 6 #1260
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 | |
| permissions: | |
| contents: read | |
| on: | |
| push: | |
| tags-ignore: | |
| - '*' | |
| branches: ['main'] | |
| pull_request: | |
| branches: ['main'] | |
| workflow_call: | |
| workflow_dispatch: | |
| inputs: | |
| debug: | |
| description: 'Open ssh debug session.' | |
| required: true | |
| default: false | |
| type: boolean | |
| schedule: | |
| - cron: '0 13 * * *' # Runs at 6 am pacific every day | |
| jobs: | |
| test-linux: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| actions: write | |
| strategy: | |
| matrix: | |
| python-version: ['3.10', '3.11', '3.12', '3.13', '3.14'] | |
| django-version: | |
| - '4.2' # LTS April 2026 | |
| - '5.1' # December 2025 | |
| - '5.2' # LTS April 2028 | |
| - '6.0rc1' # prerelease | |
| exclude: | |
| - python-version: '3.13' | |
| django-version: '4.2' | |
| - python-version: '3.14' | |
| django-version: '4.2' | |
| - python-version: '3.14' | |
| django-version: '5.1' | |
| - python-version: '3.10' | |
| django-version: '6.0rc1' | |
| - python-version: '3.11' | |
| django-version: '6.0rc1' | |
| env: | |
| COVERAGE_FILE: linux-py${{ matrix.python-version }}-dj${{ matrix.django-version }}.coverage | |
| TEST_PYTHON_VERSION: ${{ matrix.python-version }} | |
| TEST_DJANGO_VERSION: ${{ matrix.django-version }} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: 22 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v6 | |
| id: sp | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| allow-prereleases: true | |
| - name: Setup Just | |
| uses: extractions/setup-just@v3 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: true | |
| - name: Install Dependencies | |
| shell: bash | |
| run: | | |
| just setup ${{ steps.sp.outputs.python-path }} | |
| if [[ "${{ matrix.django-version }}" =~ (a|b|rc) ]]; then | |
| just test-lock Django==${{ matrix.django-version }} | |
| else | |
| just test-lock Django~=${{ matrix.django-version }}.0 | |
| fi | |
| - name: Install Emacs | |
| if: ${{ github.event.inputs.debug == 'true' }} | |
| run: | | |
| sudo apt install emacs | |
| - name: Setup tmate session | |
| if: ${{ github.event.inputs.debug == 'true' }} | |
| uses: mxschmitt/[email protected] | |
| with: | |
| detached: true | |
| timeout-minutes: 60 | |
| - name: Run Unit Tests | |
| run: | | |
| just test ./tests/verify_environment.py | |
| just test-all | |
| - name: Store coverage files | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: ${{ env.COVERAGE_FILE }} | |
| path: ${{ env.COVERAGE_FILE }} | |
| test-macos: | |
| runs-on: macos-latest | |
| permissions: | |
| actions: write | |
| strategy: | |
| matrix: | |
| python-version: ['3.10', '3.12', '3.14'] | |
| django-version: | |
| - '4.2' # LTS April 2026 | |
| - '5.2' # LTS April 2028 | |
| - '6.0rc1' # April 2027 | |
| exclude: | |
| - python-version: '3.12' | |
| django-version: '4.2' | |
| - python-version: '3.14' | |
| django-version: '4.2' | |
| - python-version: '3.10' | |
| django-version: '5.2' | |
| - python-version: '3.14' | |
| django-version: '5.2' | |
| - python-version: '3.10' | |
| django-version: '6.0rc1' | |
| - python-version: '3.12' | |
| django-version: '6.0rc1' | |
| env: | |
| COVERAGE_FILE: macos-py${{ matrix.python-version }}-dj${{ matrix.django-version }}.coverage | |
| TEST_PYTHON_VERSION: ${{ matrix.python-version }} | |
| TEST_DJANGO_VERSION: ${{ matrix.django-version }} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: 22 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v6 | |
| id: sp | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Setup Just | |
| uses: extractions/setup-just@v3 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: true | |
| - name: Install Release Dependencies | |
| run: | | |
| just setup ${{ steps.sp.outputs.python-path }} | |
| if [[ "${{ matrix.django-version }}" =~ (a|b|rc) ]]; then | |
| just test-lock Django==${{ matrix.django-version }} | |
| else | |
| just test-lock Django~=${{ matrix.django-version }}.0 | |
| fi | |
| - name: install-emacs-macos | |
| if: ${{ github.event.inputs.debug == 'true' }} | |
| run: | | |
| brew install emacs | |
| - name: Setup tmate session | |
| if: ${{ github.event.inputs.debug == 'true' }} | |
| uses: mxschmitt/[email protected] | |
| with: | |
| detached: true | |
| timeout-minutes: 60 | |
| - name: Run Unit Tests | |
| run: | | |
| just test ./tests/verify_environment.py | |
| just test-all | |
| - name: Store coverage files | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: ${{ env.COVERAGE_FILE }} | |
| path: ${{ env.COVERAGE_FILE }} | |
| test-windows: | |
| runs-on: windows-latest | |
| permissions: | |
| actions: write | |
| defaults: | |
| run: | |
| shell: pwsh | |
| strategy: | |
| matrix: | |
| python-version: ['3.10', '3.12', '3.14'] | |
| django-version: | |
| - '4.2' # LTS April 2026 | |
| - '5.2' # LTS April 2028 | |
| - '6.0rc1' # April 2027 | |
| exclude: | |
| - python-version: '3.12' | |
| django-version: '4.2' | |
| - python-version: '3.14' | |
| django-version: '4.2' | |
| - python-version: '3.10' | |
| django-version: '5.2' | |
| - python-version: '3.14' | |
| django-version: '5.2' | |
| - python-version: '3.10' | |
| django-version: '6.0rc1' | |
| - python-version: '3.12' | |
| django-version: '6.0rc1' | |
| env: | |
| COVERAGE_FILE: windows-py${{ matrix.python-version }}-dj${{ matrix.django-version }}.coverage | |
| TEST_PYTHON_VERSION: ${{ matrix.python-version }} | |
| TEST_DJANGO_VERSION: ${{ matrix.django-version }} | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-node@v6 | |
| with: | |
| node-version: 22 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v6 | |
| id: sp | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Setup Just | |
| uses: extractions/setup-just@v3 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: true | |
| - name: Install Release Dependencies | |
| run: | | |
| just setup ${{ steps.sp.outputs.python-path }} | |
| $version = "${{ matrix.django-version }}" | |
| if ($version -match "(a|b|rc)") { | |
| just test-lock "Django==$version" | |
| } else { | |
| just test-lock "Django~=$version.0" | |
| } | |
| shell: pwsh | |
| - name: install-vim-windows | |
| if: ${{ github.event.inputs.debug == 'true' }} | |
| uses: rhysd/action-setup-vim@v1 | |
| - name: Setup tmate session | |
| if: ${{ github.event.inputs.debug == 'true' }} | |
| uses: mxschmitt/[email protected] | |
| with: | |
| detached: true | |
| timeout-minutes: 60 | |
| - name: Run Unit Tests | |
| run: | | |
| just test ./tests/verify_environment.py | |
| just test-all | |
| - name: Store coverage files | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: ${{ env.COVERAGE_FILE }} | |
| path: ${{ env.COVERAGE_FILE }} | |
| coverage-combine: | |
| needs: [test-linux, test-macos, test-windows] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| id: sp | |
| with: | |
| python-version: '3.12' | |
| - name: Setup Just | |
| uses: extractions/setup-just@v3 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: true | |
| - name: Install Release Dependencies | |
| run: | | |
| just setup ${{ steps.sp.outputs.python-path }} | |
| - name: Get coverage files | |
| uses: actions/download-artifact@v6 | |
| with: | |
| pattern: "*.coverage" | |
| merge-multiple: true | |
| - run: ls -la *.coverage | |
| - run: just coverage | |
| - name: Upload coverage to Codecov | |
| uses: codecov/codecov-action@v5 | |
| with: | |
| token: ${{ secrets.CODECOV_TOKEN }} | |
| files: | |
| ./coverage.xml |