-
Notifications
You must be signed in to change notification settings - Fork 43
67 lines (55 loc) · 1.55 KB
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
name: tests
on: [push]
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up CMake
uses: jwlawson/actions-setup-cmake@v2
with:
cmake-version: '3.21.x'
- name: Set up GCC and G++
run: |
sudo apt-get update
sudo apt-get install -y build-essential
- name: Use cmake
run: cmake --version
- name: Cache CMake build
uses: actions/cache@v3
with:
path: |
~/.cache/CMake
./hiop/build
key: ${{ runner.os }}-cmake-${{ github.sha }}
restore-keys: |
${{ runner.os }}-cmake-
- name: Configure CMake
run: |
mkdir -p ${{ runner.workspace }}/hiop/build
cd ${{ runner.workspace }}/hiop/build
cmake ${{ runner.workspace }}/hiop \
-DHIOP_USE_RAJA=OFF \
-DHIOP_USE_MPI=OFF \
-DCMAKE_BUILD_TYPE=Debug \
-DHIOP_BUILD_SHARED=ON \
-DHIOP_BUILD_STATIC=ON \
-DCMAKE_INSTALL_PREFIX=.. \
-DHIOP_WITH_KRON_REDUCTION=OFF \
-DHIOP_SPARSE=OFF
- name: Build hiop
run: |
cd ${{ runner.workspace }}/hiop/build
make -j4
- name: Install hiop
run: |
cd ${{ runner.workspace }}/hiop/build
make install
- name: Run Tests
run: |
cd ${{ runner.workspace }}/hiop/build
make test