-
-
Notifications
You must be signed in to change notification settings - Fork 3
38 lines (38 loc) · 1.42 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
on: push
jobs:
Test:
runs-on: ${{ matrix.OS }}
strategy:
matrix:
OS: ["ubuntu-latest", "windows-latest", "macos-latest"]
CXX: ["g++", "clang++"]
trace: ["-DJNIVM_ENABLE_TRACE=OFF", "-DJNIVM_ENABLE_TRACE=ON"]
examples: ["-DJNIVM_BUILD_EXAMPLES=OFF", "-DJNIVM_BUILD_EXAMPLES=ON"]
codegen: ["-DJNIVM_USE_FAKE_JNI_CODEGEN=OFF", "-DJNIVM_USE_FAKE_JNI_CODEGEN=ON"]
exclude:
- OS: "windows-latest"
CXX: "g++" # Windows ignores CXX, so just remove g++
- OS: "macos-latest"
CXX: "g++" # macOS uses a symlink to clang++, so just remove g++
include:
- OS: "windows-latest"
suffix: .exe
intdir: Debug/
steps:
- name: Checkout
uses: actions/checkout@main
- name: Configure
env:
CXX: ${{matrix.CXX}}
run: |
echo Configure with compiler $CXX
mkdir build
cd build
cmake .. -DJNIVM_ENABLE_TESTS=ON -DJNIVM_ENABLE_RETURN_NON_ZERO=ON ${{matrix.trace}} ${{matrix.examples}} ${{matrix.codegen}}
- name: Build
run: |
cd build
cmake --build .
- name: Run Tests
run: |
./build/${{matrix.intdir}}JNIVMTests${{matrix.suffix}}