Add some Firedrake testing #4
Workflow file for this run
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: 'Build and test specfab' | |
on: [push, pull_request] | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ["3.10", "3.11"] | |
steps: | |
- name: Check out git repository | |
uses: actions/checkout@v4 | |
- name: Set up Python-${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: | | |
sudo apt-get install -y libnetcdff-dev | |
python -m pip install "numpy<2" "setuptools<65" | |
- name: Build package | |
working-directory: ./src | |
run: | | |
make all | |
make python | |
make constitutive-tests | |
make aux-tests | |
- name: Run test suite | |
working-directory: ./tests | |
run: | | |
constitutive-equations/elasticity-test-transverselyisotropic | |
constitutive-equations/rheology-test-isotropic-porous | |
constitutive-equations/rheology-test-orthotropic | |
constitutive-equations/rheology-test-transverselyisotropic | |
reduced-coef-test/reduced-coef-test | |
wigner-d-rotation-test/discrete-rotation-test | |
test-firedrake: | |
runs-on: ubuntu-latest | |
container: | |
image: docker.io/firedrakeproject/firedrake-vanilla:2024-05 | |
options: --user root | |
steps: | |
- name: Check out git repository | |
uses: actions/checkout@v4 | |
- name: Activate firedrake virtual environment | |
run: | | |
. /home/firedrake/firedrake/bin/activate | |
echo PATH=$PATH >> $GITHUB_ENV | |
- name: Install dependences | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y libnetcdff-dev | |
python -m pip install "numpy<2" "setuptools < 65" cartopy cmasher | |
- name: Build package | |
working-directory: ./src | |
run: make all | |
- name: Install Python package | |
working-directory: ./src | |
run: | | |
make specfabpy | |
python -m pip install . | |
- name: Run test suite | |
working-directory: ./tests | |
run: python firedrake/simpleshear-rathmann.py |