diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index b89453ec319c92bf5a7048f6b787c621771525d0..41e3a70865bdfbd60e238b7911ce99a4c977ec18 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -23,12 +23,10 @@ typechecker: script: - nox --session typecheck -testsuite: +.testsuite-base: extends: .nox-base stage: "Tests" needs: [] - script: - - nox --session testsuite coverage: '/TOTAL.*\s+(\d+%)$/' artifacts: when: always @@ -40,6 +38,16 @@ testsuite: coverage_format: cobertura path: coverage.xml +"testsuite-py3.10": + extends: .testsuite-base + script: + - nox --session testsuite-3.10 + +"testsuite-py3.13": + extends: .testsuite-base + script: + - nox --session testsuite-3.13 + build-documentation: extends: .nox-base stage: "Documentation" diff --git a/noxfile.py b/noxfile.py index 915ab84dcd70663a7c2c7644212e6aded5484d50..a725b7bafcb43caee4f90e60bc509c1413a061a9 100644 --- a/noxfile.py +++ b/noxfile.py @@ -11,7 +11,14 @@ def add_pystencils_git(session: nox.Session): cache_dir = session.cache_dir pystencils_dir = cache_dir / "pystencils" - if not pystencils_dir.exists(): + if pystencils_dir.exists(): + with session.chdir(pystencils_dir): + session.run_install( + "git", + "pull", + external=True + ) + else: session.run_install( "git", "clone", @@ -50,7 +57,7 @@ def typecheck(session: nox.Session): session.run("mypy", "src/pystencilssfg") -@nox.session(python=["3.10"], tags=["tests"]) +@nox.session(python=["3.10", "3.11", "3.12", "3.13"], tags=["tests"]) def testsuite(session: nox.Session): """Run the testsuite and measure coverage.""" editable_install(session, ["testsuite"])