Skip to content

Commit

Permalink
fixed python3.12 failing CI tests (#4118)
Browse files Browse the repository at this point in the history
  • Loading branch information
santacodes committed May 29, 2024
1 parent a427b3a commit c733b73
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ def run_pybamm_requires(session):
def run_coverage(session):
"""Run the coverage tests and generate an XML report."""
set_environment_variables(PYBAMM_ENV, session=session)
session.install("setuptools", silent=False)
session.install("coverage", silent=False)
session.install("-e", ".[all,dev,jax]", silent=False)
session.run("pytest", "--cov=pybamm", "--cov-report=xml", "tests/unit")
Expand All @@ -70,6 +71,7 @@ def run_coverage(session):
def run_integration(session):
"""Run the integration tests."""
set_environment_variables(PYBAMM_ENV, session=session)
session.install("setuptools", silent=False)
session.install("-e", ".[all,dev,jax]", silent=False)
session.run("python", "run-tests.py", "--integration")

Expand All @@ -88,6 +90,7 @@ def run_doctests(session):
def run_unit(session):
"""Run the unit tests."""
set_environment_variables(PYBAMM_ENV, session=session)
session.install("setuptools", silent=False)
session.install("-e", ".[all,dev,jax]", silent=False)
session.run("python", "run-tests.py", "--unit")

Expand All @@ -96,6 +99,7 @@ def run_unit(session):
def run_examples(session):
"""Run the examples tests for Jupyter notebooks."""
set_environment_variables(PYBAMM_ENV, session=session)
session.install("setuptools", silent=False)
session.install("-e", ".[all,dev]", silent=False)
notebooks_to_test = session.posargs if session.posargs else []
session.run("pytest", "--nbmake", *notebooks_to_test, external=True)
Expand Down Expand Up @@ -139,6 +143,7 @@ def set_dev(session):
def run_tests(session):
"""Run the unit tests and integration tests sequentially."""
set_environment_variables(PYBAMM_ENV, session=session)
session.install("setuptools", silent=False)
session.install("-e", ".[all,dev,jax]", silent=False)
session.run("python", "run-tests.py", "--all")

Expand Down

0 comments on commit c733b73

Please sign in to comment.