Skip to content

Unit testing and benchmarking libCEED integration with Catch2 #466

Unit testing and benchmarking libCEED integration with Catch2

Unit testing and benchmarking libCEED integration with Catch2 #466

Workflow file for this run

name: Spack
on:
push:
branches:
- main
pull_request:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build-and-test-spack:
strategy:
fail-fast: false
matrix:
include:
- compiler: gcc
mpi: openmpi
runs-on: palace_ubuntu-latest_16-core
steps:
- uses: actions/checkout@v3
- uses: mpi4py/setup-mpi@v1
with:
mpi: ${{ matrix.mpi }}
- name: Configure Clang compiler
if: matrix.compiler == 'clang'
run: |
sudo apt-get install -y clang lld
- uses: vsoch/spack-package-action/install@main
- name: Build Palace
run: |
# Clean up Android SDK install (confuses Spack MKL link line?)
sudo rm -rf $ANDROID_HOME
# Set up Spack to use external packages (MPI, etc.)
. /opt/spack/share/spack/setup-env.sh
spack external find --all
# Build and install
spack repo add spack/local
spack dev-build local.palace@develop%${{ matrix.compiler }} ^petsc~hdf5 ^intel-oneapi-mkl
- name: Run tests
env:
NUM_PROC_TEST_MAX: '8'
run: |
# Configure environment
export NUM_PROC_TEST=$(nproc 2> /dev/null || sysctl -n hw.ncpu)
if [[ "$NUM_PROC_TEST" -gt "$NUM_PROC_TEST_MAX" ]]; then
NUM_PROC_TEST=$NUM_PROC_TEST_MAX
fi
. /opt/spack/share/spack/setup-env.sh
spack load palace
# Run tests
julia --project=test/examples -e 'using Pkg; Pkg.instantiate()'
julia --project=test/examples --color=yes test/examples/runtests.jl