-
Notifications
You must be signed in to change notification settings - Fork 18
38 lines (32 loc) · 1.15 KB
/
build.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
name: cmake build
on:
pull_request:
branches: [ "master" ]
jobs:
build:
runs-on: ubu20cuda11 # ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build
run: |
mkdir ${{github.workspace}}/build
cd ${{github.workspace}}/build
cmake -DCMAKE_INSTALL_PREFIX=/tmp/carlsim6 \
-DCMAKE_BUILD_TYPE=Release .. \
-DCARLSIM_GH_ACTIONS=ON
make -j$(nproc) install
- name: Run tests
run: |
cd ${{github.workspace}}
./build/carlsim/test/carlsim-tests
./build/carlsim/test6/carlsim-tests6
lcov --directory ./ --capture --output-file ./code_coverage.lcov \
-rc lcov_branch_coverage=1
lcov --remove ./code_coverage.lcov -o ./code_coverage.lcov \
'/usr/*' '/tmp/*' '${{github.workspace}}/build/*'
- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: ${{github.workspace}}/code_coverage.lcov
debug: False # True