Skip to content

Commit dadfc43

Browse files
Merge pull request #6 from Fuad-HH/github_actions_2
Github Actions Added
2 parents 78f2983 + 2a98d54 commit dadfc43

2 files changed

Lines changed: 57 additions & 0 deletions

File tree

.github/workflows/RunTests.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: RunTests
2+
3+
on: push
4+
5+
jobs:
6+
TestMesh:
7+
name: TestMesh
8+
runs-on: ubuntu-22.04
9+
10+
defaults:
11+
run:
12+
shell: bash
13+
14+
steps:
15+
16+
- name: UpdatePackages
17+
run: sudo apt-get update
18+
19+
- name: CheckoutRepository
20+
uses: actions/checkout@v4
21+
22+
- name: Build
23+
run: bash ${GITHUB_WORKSPACE}/ActionsInstall.sh
24+
25+
- name: TestCode
26+
run: |
27+
cd build/
28+
export OMP_NUM_THREADS=2
29+
export OMP_PLACES=threads
30+
export OMP_PROC_BIND=spread
31+
make test
32+
33+
- name: Results
34+
run: cd build/Testing/Temporary && cat LastTest.log
35+

ActionsInstall.sh

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
git clone https://github.com/catchorg/Catch2 ../Catch2
2+
cmake -S ../Catch2 -B ../Catch2/build/ \
3+
-DCMAKE_INSTALL_PREFIX=../Catch2/build/install/
4+
cmake --build ../Catch2/build/ -j 8 --target install
5+
6+
export CMAKE_PREFIX_PATH=$CMAKE_PREFIX_PATH:../Catch2/build/install
7+
8+
git clone https://github.com/kokkos/kokkos.git ../Kokkos
9+
cmake -S ../Kokkos -B ../Kokkos/build/ \
10+
-DCMAKE_BUILD_TYPE=Debug \
11+
-DCMAKE_CXX_COMPILER=`which g++` \
12+
-DCMAKE_INSTALL_PREFIX=../Kokkos/build/install/ \
13+
-DKokkos_ENABLE_OPENMP=ON
14+
cmake --build ../Kokkos/build/ -j 8 --target install
15+
16+
export CMAKE_PREFIX_PATH=$CMAKE_PREFIX_PATH:../Kokkos/build/install
17+
18+
cmake -S . -B build \
19+
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
20+
-DCMAKE_CXX_COMPILER=`which g++` \
21+
-DAssignment_ENABLE_CUDA=OFF
22+
cmake --build build -j 8

0 commit comments

Comments
 (0)