blob: 72c4159d1e41eb2d82ac93bbeeba104a379a7c59 [file] [log] [blame]
name: Celix Coverage
on: [push, pull_request]
jobs:
coverage:
runs-on: ubuntu-20.04
steps:
- name: Checkout source code
uses: actions/checkout@v2
- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -yq --no-install-recommends \
build-essential \
curl \
uuid-dev \
libjansson-dev \
libcurl4-openssl-dev \
default-jdk \
cmake \
libffi-dev \
libxml2-dev \
libczmq-dev \
libcpputest-dev \
rapidjson-dev \
lcov
- name: Build
env:
BUILD_OPTIONS: |
-DENABLE_TESTING=ON
-DENABLE_CODE_COVERAGE=ON
-DBUILD_EXPERIMENTAL=ON
run: |
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Debug ${BUILD_OPTIONS} ..
make -j
- name: Coverage
run: |
cd $GITHUB_WORKSPACE/build
export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH:$(pwd)/utils:$(pwd)/framework:$(pwd)/dfi
make coverage
lcx="lcov --output-file=coverage.info " && for i in `find . -name "*.info.cleaned"`; do lcx+=" --add-tracefile=$i"; done && $lcx
- name: Codecov
uses: codecov/codecov-action@e156083f13aff6830c92fc5faa23505779fbf649
with:
file: build/coverage.info
name: codecov-celix
# NOTE For now disabled, need to be able to configure coveralls thresholds
# See https://github.com/lemurheavy/coveralls-public/issues/1431
# - name: Coveralls
# uses: coverallsapp/github-action@master
# with:
# github-token: ${{ secrets.GITHUB_TOKEN }}
# path-to-lcov: build/coverage.info