Skip to content

Commit

Permalink
Add unittests
Browse files Browse the repository at this point in the history
  • Loading branch information
jan-janssen committed Oct 3, 2024
1 parent 9588879 commit 0bf3428
Show file tree
Hide file tree
Showing 12 changed files with 2,057 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .ci_support/environment-notebooks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
channels:
- conda-forge
dependencies:
- jupyter
- papermill
- pyiron-data =0.0.30
- pyiron_atomistics =0.6.13
- lammps =2024.02.07=*_openmpi_*
- sphinxdft =3.1
5 changes: 5 additions & 0 deletions .ci_support/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
channels:
- conda-forge
dependencies:
- h5io_browser =0.1.2
- pint =0.24.3
29 changes: 29 additions & 0 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Integrationtests

on:
push:
branches: [ main ]
pull_request:

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Conda config
shell: bash -l {0}
run: echo -e "channels:\n - conda-forge\n" > .condarc
- name: Setup Mambaforge
uses: conda-incubator/setup-miniconda@v3
with:
python-version: "3.12"
miniforge-version: latest
condarc-file: .condarc
environment-file: .ci_support/environment-notebooks.yml
- name: Test
shell: bash -l {0}
timeout-minutes: 5
run: |
pip install .
papermill notebooks/lammps.ipynb lammps_out.ipynb -k python3
papermill notebooks/sphinxdft.ipynb sphinxdft_out.ipynb -k python3
28 changes: 28 additions & 0 deletions .github/workflows/unittests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Unittests

on:
push:
branches: [ main ]
pull_request:

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Conda config
shell: bash -l {0}
run: echo -e "channels:\n - conda-forge\n" > .condarc
- name: Setup Mambaforge
uses: conda-incubator/setup-miniconda@v3
with:
python-version: "3.12"
miniforge-version: latest
condarc-file: .condarc
environment-file: .ci_support/environment.yml
- name: Test
shell: bash -l {0}
timeout-minutes: 5
run: |
pip install .
python -m unittest discover tests
427 changes: 427 additions & 0 deletions notebooks/lammps.ipynb

Large diffs are not rendered by default.

507 changes: 507 additions & 0 deletions notebooks/sphinxdft.ipynb

Large diffs are not rendered by default.

Empty file added tests/__init__.py
Empty file.
Loading

0 comments on commit 0bf3428

Please sign in to comment.