summaryrefslogtreecommitdiff
path: root/.github/workflows/coverage.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/coverage.yml')
-rw-r--r--.github/workflows/coverage.yml58
1 files changed, 46 insertions, 12 deletions
diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml
index 74db0715..dac9664f 100644
--- a/.github/workflows/coverage.yml
+++ b/.github/workflows/coverage.yml
@@ -2,24 +2,24 @@ name: coverage
on: [push]
jobs:
- build:
- name: build
- runs-on: ${{ matrix.os }}
- strategy:
- matrix:
- os: [ ubuntu-latest ]
+ linux-coverage:
+ name: linux
+ runs-on: [ ubuntu-latest ]
steps:
- name: Check out code
uses: actions/checkout@v1
+ - name: Install mbedTLS
+ run: sudo apt-get install libmbedtls-dev
+
+ - name: Install ninja
+ run: sudo apt-get install ninja-build
+
- name: Configure
- run: |
- mkdir build
- cd build
- cmake -D NNG_ENABLE_COVERAGE=ON ..
+ run: mkdir build && cd build && cmake -G Ninja -DNNG_ENABLE_COVERAGE=ON -DNNG_ENABLE_TLS=ON ..
- name: build
- run: cmake --build build
+ run: cd build && ninja
- name: Test
run: cd build && ctest --output-on-failure
@@ -28,4 +28,38 @@ jobs:
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
- yml: ./.codecov.yml \ No newline at end of file
+ yml: ./.codecov.yml
+
+ darwin-coverage:
+ name: darwin
+ runs-on: [ macos-latest ]
+ steps:
+ - name: Check out code
+ uses: actions/checkout@v1
+
+ - name: Install mbedTLS
+ run: brew install mbedtls
+
+ - name: Install ninja
+ run: brew install ninja
+
+ - name: Install lcov
+ run: brew install lcov
+
+ - name: Configure
+ run: mkdir build && cd build && cmake -G Ninja -DNNG_ENABLE_COVERAGE=ON -DNNG_ENABLE_TLS=ON ..
+
+ - name: build
+ run: cd build && ninja
+
+ - name: Test
+ run: cd build && ctest --output-on-failure
+
+ - name: Preprocess
+ run: cd build && lcov -c -d . -o lcov.info
+
+ - name: Upload report
+ uses: codecov/codecov-action@v1
+ with:
+ token: ${{ secrets.CODECOV_TOKEN }}
+ yml: ./.codecov.yml