Update ukb-atlas demo #191
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test package | |
on: | |
pull_request: | |
push: | |
branches: [main] | |
jobs: | |
test-code: | |
name: Test on ${{ matrix.container }} | |
runs-on: ubuntu-24.04 | |
container: ${{ matrix.container }} | |
env: | |
DEB_PYTHON_INSTALL_LAYOUT: deb_system | |
strategy: | |
fail-fast: false | |
matrix: | |
container: [ | |
"ghcr.io/fenics/dolfinx/dolfinx:stable", | |
"ghcr.io/fenics/dolfinx/dolfinx:nightly", | |
] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install package | |
run: | | |
python3 -m pip install scifem --no-build-isolation | |
python3 -m pip install .[test] | |
- name: Run tests | |
run: python3 -m pytest -v --cov=cardiac_geometries --cov-report html --cov-report xml --cov-report term-missing | |
- name: Extract Coverage | |
run: | | |
python3 -m coverage report | sed 's/^/ /' >> $GITHUB_STEP_SUMMARY | |
python3 -m coverage json | |
export TOTAL=$(python3 -c "import json;print(json.load(open('coverage.json'))['totals']['percent_covered_display'])") | |
echo "total=$TOTAL" >> $GITHUB_ENV | |
- name: Upload HTML report. | |
uses: actions/upload-artifact@v4 | |
if: ${{ matrix.container == 'ghcr.io/fenics/dolfinx/dolfinx:stable' }} | |
with: | |
name: html-report | |
path: htmlcov |