OneApi fix #182
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: Red Hat clone | |
on: | |
pull_request: | |
branches: | |
- main | |
push: | |
branches: | |
- "main" | |
tags: | |
- "v*" | |
merge_group: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
container: fenicsproject/test-env:current-redhat | |
name: Rocky build and test | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Python dependencies | |
run: | | |
python3 -m pip install mpi4py nanobind scikit-build-core[pyproject] --upgrade | |
- name: Install FEniCS Python components | |
run: | | |
python3 -m pip install --no-cache-dir --upgrade pip setuptools | |
python3 -m pip install git+https://github.com/FEniCS/ufl.git | |
python3 -m pip install git+https://github.com/FEniCS/basix.git | |
python3 -m pip install git+https://github.com/FEniCS/ffcx.git | |
- name: Configure C++ | |
run: cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build -S cpp/ | |
- name: Build and install C++ library | |
run: | | |
cmake --build build | |
cmake --install build | |
- name: Build C++ unit tests | |
run: | | |
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/test/ -S cpp/test/ | |
cmake --build build/test | |
- name: Run C++ unit tests (serial) | |
run: | | |
cd build/test | |
ctest -V --output-on-failure -R unittests | |
- name: Run C++ unit tests (MPI) | |
run: | | |
cd build/test | |
mpiexec -np 2 ctest -V --output-on-failure -R unittests | |
- name: Build and run C++ regression tests (serial and MPI (np=2)) | |
run: | | |
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build/demo/ -S cpp/demo/ | |
cmake --build build/demo | |
cd build/demo | |
ctest -V -R demo -R serial | |
ctest -V -R demo -R mpi_2 | |
- name: Install Python dependencies | |
run: | | |
python3 -m pip install cffi numba scikit-build-core[pyproject] pytest pytest-xdist scipy matplotlib | |
- name: Build Python interface (editable install) | |
run: | | |
python3 -m pip install --check-build-dependencies --no-build-isolation --config-settings=cmake.build-type=Debug --config-settings=build-dir="build" -e python/ | |
- name: Set default DOLFINx JIT options | |
run: | | |
mkdir -p ~/.config/dolfinx | |
echo '{ "cffi_extra_compile_args": ["-g0", "-O0" ] }' > ~/.config/dolfinx/dolfinx_jit_options.json | |
- name: Install test Python dependencies | |
run: python3 -m pip install matplotlib numba pytest pytest-xdist scipy | |
- name: Run demos (Python, serial) | |
run: python3 -m pytest -n auto -m serial --durations=10 python/demo/test.py | |
- name: Run demos (Python, MPI (np=2)) | |
run: python3 -m pytest -m mpi --num-proc=2 python/demo/test.py | |
- name: Run Python unit tests (serial) | |
run: python3 -m pytest -n auto -m "not adios2" --durations=50 python/test/unit/ | |
- name: Run Python unit tests (MPI, np=2) | |
run: mpirun -np 2 python3 -m pytest -m "not adios2" python/test/unit/ |