move coverage to GH actions

This commit is contained in:
John
2021-11-11 21:51:03 +01:00
parent 3227ffcfde
commit 278e1ea7ae
3 changed files with 35 additions and 23 deletions
+34
View File
@@ -0,0 +1,34 @@
name: Coverage
on:
push:
branches: [ master ]
jobs:
coverage:
runs-on: ubuntu-latest
steps:
-
name: checkout
uses: actions/checkout@v2
-
name: packages
run: apt-get update && apt-get install -y libmosquitto1 libmosquitto1-dev
-
name: build
run: cmake -Dcoverage=ON -DBUILD_TESTING . && make
-
name: test regular
run: cd src/lib/ebus/test && ./test_symbol && ./test_filereader && ./test_data && ./test_message
-
name: test contrib
run: cd src/lib/ebus/contrib/test && ./test_contrib
-
name: test coverage
run: ./test_coverage.sh
-
name: prepare result
run: find . -type f -name '*.gcno' -exec bash -c "(f={}; ls -l \$f; cd \${f%/*}; gcov -pb \${f##*/})" \;
-
name: push result
run: bash <(curl -s https://codecov.io/bash) -X gcov
-22
View File
@@ -1,22 +0,0 @@
dist: trusty
language: cpp
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-4.8
- php5-cli
before_install:
- sudo apt-get -qq update
- sudo apt-get install -y libmosquitto0 libmosquitto0-dev
- export CXX=g++-4.8
script:
- ./autogen.sh --enable-coverage && make all test
- (cd src/lib/ebus/test && ./test_symbol && ./test_filereader && ./test_data && ./test_message)
- (cd src/lib/ebus/contrib/test && ./test_contrib)
- ./src/ebusd/ebusd --help
- ./test_coverage.sh
after_success:
- find . -type f -name '*.gcno' -exec bash -c "(f={}; ls -l \$f; cd \${f%/*}; gcov-4.8 -pb \${f##*/})" \;
- bash <(curl -s https://codecov.io/bash) -X gcov
+1 -1
View File
@@ -335,7 +335,7 @@ curl -s "http://localhost:8878/data/?verbose=1" >/dev/null
curl -s "http://localhost:8878/data/?indexed=1&numeric=1" >/dev/null
curl -s "http://localhost:8878/data/?full" >/dev/null
curl -s "http://localhost:8878/data/mc.5/installparam?poll=1&user=test&secret=testpass" >/dev/null
curl -T .travis.yml http://localhost:8878/data/
curl -T test_coverage.sh http://localhost:8878/data/
echo `date` "commands done"
kill $lstpid
verify=`./src/tools/ebusctl -p 8877 info|egrep "^address 04:"`