Skip to content

...

... #515

Workflow file for this run

# .github/workflows/app.yaml
name: ngsPETSc tests
on:
push:
branches-ignore:
- 'no-ci/*'
schedule:
- cron: '30 10 7,14,21,28 * *'
jobs:
lint:
runs-on: ubuntu-latest
container: urzerbinati/ngspetsc:latest
timeout-minutes: 3
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Install ngsPETSc
run: |
python -m pip install .
pip install pylint
- name: Lint
run: |
make lint GITHUB_ACTIONS_FORMATTING=1
make lint_test GITHUB_ACTIONS_FORMATTING=1
ngsolve:
runs-on: ubuntu-latest
container: urzerbinati/ngspetsc:latest
timeout-minutes: 30
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Install ngsPETSc
run: |
python -m pip install .
- name: Run test suite in serial
run: |
pytest -v tests/test_env.py
pytest -v tests/test_vec.py
pytest -v tests/test_mat.py
pytest -v tests/test_plex.py
pytest -v tests/test_ksp.py
pytest -v tests/test_pc.py
pytest -v tests/test_eps.py
pytest -v tests/test_snes.py
- name: Run test suite in parallel
run: |
mpirun --allow-run-as-root -n 2 pytest -v --with-mpi tests/test_env.py
mpirun --allow-run-as-root -n 2 pytest -v --with-mpi tests/test_vec.py
mpirun --allow-run-as-root -n 2 pytest -v --with-mpi tests/test_mat.py
mpirun --allow-run-as-root -n 2 pytest -v --with-mpi tests/test_plex.py
mpirun --allow-run-as-root -n 2 pytest -v --with-mpi tests/test_ksp.py
mpirun --allow-run-as-root -n 2 pytest -v --with-mpi tests/test_pc.py
mpirun --allow-run-as-root -n 2 pytest -v --with-mpi tests/test_eps.py
mpirun --allow-run-as-root -n 2 pytest -v --with-mpi tests/test_snes.py
fenicsx:
runs-on: ubuntu-latest
container:
image: dolfinx/dolfinx:nightly
options: --user root
timeout-minutes: 50
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Install pytest
run: |
pip install pytest --break-system-packages
- name: Install Netgen and ngsPETSc
run: |
pip install netgen-mesher --break-system-packages
export PYTHONPATH=$PYTHONPATH:/usr/local/lib/python3.10/site-packages
echo "PYTHONPATH=$PYTHONPATH" >> $GITHUB_ENV
NGSPETSC_NO_INSTALL_REQUIRED=ON pip install -e . --break-system-packages
- name: Run test suite in serial
run: |
pytest -v tests/test_fenicsx.py
firedrake:
runs-on: ubuntu-latest
container:
image: firedrakeproject/firedrake-vanilla:latest
options: --user root
timeout-minutes: 50
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Add SLEPc to vanilla Firedrake
run: |
. /home/firedrake/firedrake/bin/activate
cp -R $SLEPC_DIR/src/binding/slepc4py $VIRTUAL_ENV/src
pip install --no-build-isolation --no-binary mpi4py,randomgen,numpy --no-deps $VIRTUAL_ENV/src/slepc4py/
- name: Install Netgen and ngsPETSc
run: |
. /home/firedrake/firedrake/bin/activate
pip install netgen-mesher
pip install xdist pytest-timeout ipympl
NGSPETSC_NO_INSTALL_REQUIRED=ON pip install .
- name: Run part of the Firedrake test suite
run: |
. /home/firedrake/firedrake/bin/activate
cd $VIRTUAL_ENV/src/firedrake
pytest tests/regression/test_poisson_strong_bcs.py
pytest tests/multigrid/test_netgen_gmg.py
pytest tests/regression/test_netgen.py