diff --git a/.github/workflows/scheduled_tests.yaml b/.github/workflows/scheduled_tests.yaml index 5066ede7..9cd68e62 100644 --- a/.github/workflows/scheduled_tests.yaml +++ b/.github/workflows/scheduled_tests.yaml @@ -87,8 +87,8 @@ jobs: - name: Unit tests with nox run: python -m nox -s coverage - - name: Run notebooks with nox - run: python -m nox -s notebooks + - name: Run examples with nox + run: python -m nox -s examples # M-series Mac Mini build-apple-mseries: @@ -112,14 +112,14 @@ jobs: pyenv install ${{ matrix.python_version }} -s pyenv virtualenv ${{ matrix.python_version }} pybop-${{ matrix.python_version }}-${{ matrix.pybamm_version }} - - name: Install dependencies & run unit + notebook tests + - name: Install dependencies & run tests shell: bash run: | eval "$(pyenv init -)" pyenv activate pybop-${{ matrix.python_version }}-${{ matrix.pybamm_version }} python -m pip install --upgrade pip nox python -m nox -s coverage - python -m nox -s notebooks + python -m nox -s examples - name: Uninstall pyenv-virtualenv & python if: always() diff --git a/.github/workflows/test_on_push.yaml b/.github/workflows/test_on_push.yaml index af98e8ad..c58ef5e5 100644 --- a/.github/workflows/test_on_push.yaml +++ b/.github/workflows/test_on_push.yaml @@ -113,10 +113,6 @@ jobs: run: | nox -s examples - - name: Run notebooks - run: | - nox -s notebooks - # Runs only on Ubuntu with Python 3.12 check_coverage: needs: style diff --git a/CHANGELOG.md b/CHANGELOG.md index 27b9e0c7..32fbeb1f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ ## Features +- [#273](https://github.com/pybop-team/PyBOP/pull/273) - Adds notebooks to nox examples session and updates CI workflows for change. - [#250](https://github.com/pybop-team/PyBOP/pull/250) - Adds DFN, MPM, MSMR models and moves multiple construction variables to BaseEChem. Adds exception catch on simulate & simulateS1. - [#241](https://github.com/pybop-team/PyBOP/pull/241) - Adds experimental circuit model fitting notebook with LG M50 data. - [#268](https://github.com/pybop-team/PyBOP/pull/268) - Fixes the GitHub Release artifact uploads, allowing verification of diff --git a/noxfile.py b/noxfile.py index abd72265..4ebdcfec 100644 --- a/noxfile.py +++ b/noxfile.py @@ -51,13 +51,15 @@ def integration(session): @nox.session def examples(session): + """Run the examples and notebooks""" session.install("-e", ".[all,dev]", silent=False) session.run("pytest", "--examples") + notebooks(session) @nox.session def notebooks(session): - """Run the examples tests for Jupyter notebooks.""" + """Run the Jupyter notebooks.""" session.install("-e", ".[all,dev]", silent=False) if PYBOP_SCHEDULED: session.run("pip", "install", f"pybamm=={PYBAMM_VERSION}", silent=False)