add python3.12 to CI #186
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: Tests | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| ocaml-compiler: | |
| - "5.2.0" | |
| coq-version: | |
| - "8.17.1" | |
| - "8.18.0" | |
| - "8.19.2" | |
| - "8.20.0" | |
| python-version: | |
| - '3.11' | |
| - '3.12' | |
| steps: | |
| - name: Checkout | |
| uses: actions/[email protected] | |
| - name: Set up Python | |
| uses: actions/[email protected] | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install Python dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements.txt | |
| - name: Restore opam | |
| id: cache-opam-restore | |
| uses: actions/cache/restore@v4 | |
| with: | |
| path: | | |
| /home/runner/work/coqpyt/coqpyt/_opam/ | |
| key: ${{ matrix.ocaml-compiler }}-${{ matrix.coq-version }}-opam | |
| - name: Set-up OCaml | |
| uses: ocaml/setup-ocaml@v3 | |
| with: | |
| ocaml-compiler: ${{ matrix.ocaml-compiler }} | |
| - name: Install coq-lsp | |
| if: steps.cache-opam-restore.outputs.cache-hit != 'true' | |
| run: | | |
| opam pin add coq ${{ matrix.coq-version }} | |
| opam install coq-lsp | |
| - name: Add coq-released | |
| if: steps.cache-opam-restore.outputs.cache-hit != 'true' | |
| run: | | |
| opam repo add coq-released https://coq.inria.fr/opam/released | |
| - name: Install coq-equations | |
| if: steps.cache-opam-restore.outputs.cache-hit != 'true' | |
| run: | | |
| opam install coq-equations | |
| - name: Install coqpyt | |
| run: | | |
| pip install -e . | |
| - name: Run tests | |
| run: | | |
| eval $(opam env) | |
| cd coqpyt | |
| pytest tests -s --runextra | |
| - name: Save opam | |
| id: cache-opam-save | |
| uses: actions/cache/save@v4 | |
| with: | |
| path: | | |
| /home/runner/work/coqpyt/coqpyt/_opam/ | |
| key: ${{ steps.cache-opam-restore.outputs.cache-primary-key }} |