-
Notifications
You must be signed in to change notification settings - Fork 3
47 lines (47 loc) · 1.36 KB
/
build-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
name: build
run-name: ${{ github.actor }} is testing barkeep
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build-and-test-for-cpp:
name: "Build and test for C++"
timeout-minutes: 10
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: true
- run: |
sudo apt-get install lcov
make -j2
./test.out
gcov -b -p -c test.gcno && \
lcov -c -d . -o cov.info && \
lcov --remove cov.info '/usr/local/include*' '/usr/include*' '*/subprojects/*' '*/test.cpp*' -o barkeep.info
rm cov.info
- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: barkeep.info
# - run: ./demo.out
build-and-test-for-python:
name: "Build and test for Python"
timeout-minutes: 10
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: false
- uses: actions/setup-python@v4
with:
python-version: '3.9'
- run: |
pip install meson pytest
sudo apt install ninja-build
meson setup build --buildtype=release --warnlevel=3
meson compile -C build python
PYTHONPATH=build/python pytest python/tests/test.py