diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 06666ff..a9c206b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,3 +19,8 @@ jobs: needs: check_pr_status if: needs.check_pr_status.outputs.branch-pr == '' uses: ./.github/workflows/formatter.yml + + unit_tests: + needs: check_pr_status + if: needs.check_pr_status.outputs.branch-pr == '' + uses: ./.github/workflows/unit_tests.yml diff --git a/.github/workflows/formatter.yml b/.github/workflows/formatter.yml index 1ff8b06..cfd5aab 100644 --- a/.github/workflows/formatter.yml +++ b/.github/workflows/formatter.yml @@ -1,4 +1,4 @@ -name: Ruff and unit tests +name: Ruff on: [workflow_call] jobs: Ruff: @@ -14,18 +14,3 @@ jobs: run: ruff check . - name: Check formatting run: ruff format --check . - UnitTests: - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - python-version: ["3.11", "3.14"] - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 - with: - python-version: ${{ matrix.python-version }} - - name: Install dependencies - run: python -m pip install -e '.[dev]' - - name: Run unit tests - run: python -m pytest --random-order -q test diff --git a/.github/workflows/unit_tests.yml b/.github/workflows/unit_tests.yml new file mode 100644 index 0000000..5e9f92d --- /dev/null +++ b/.github/workflows/unit_tests.yml @@ -0,0 +1,18 @@ +name: Unit tests +on: [workflow_call] +jobs: + UnitTests: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + python-version: ["3.12", "3.13", "3.14"] + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: python -m pip install -e '.[dev]' + - name: Run unit tests + run: python -m pytest --random-order -q test diff --git a/README.md b/README.md index 47a172f..a03b3eb 100644 --- a/README.md +++ b/README.md @@ -51,4 +51,4 @@ ruff format --check . python -m pytest --random-order -q test ``` -Unit tests run on Python 3.11 and 3.14. Other CI checks use Python 3.13. +Unit tests run on Python 3.12, 3.13, and 3.14. Other CI checks use Python 3.13.