File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change 22
22
build-net-tokio-tokio : true
23
23
- toolchain : 1.39.0
24
24
build-net-tokio : true
25
+ coverage : true
25
26
runs-on : ubuntu-latest
26
27
steps :
27
28
- name : Checkout source code
44
45
- name : Test on Rust ${{ matrix.toolchain }}
45
46
if : ${{ matrix.build-net-tokio }} != true
46
47
run : RUSTFLAGS="-C link-dead-code" cargo test --verbose -p lightning
48
+ - name : Install kcov
49
+ if : ${{ matrix.coverage }}
50
+ run : |
51
+ wget https://github.com/SimonKagstrom/kcov/archive/master.tar.gz
52
+ tar xzf master.tar.gz
53
+ cd kcov-master &&mkdir build && cd build
54
+ cmake .. && make
55
+ make install DESTDIR=../../kcov-build
56
+ cd ../.. && rm -rf kcov-master
57
+ - name : Upload coverage
58
+ if : ${{ matrix.coverage }}
59
+ run : |
60
+ for file in target/debug/lightning-*; do
61
+ [ -x "${file}" ] || continue;
62
+ mkdir -p "target/cov/$(basename $file)";
63
+ ./kcov-build/usr/local/bin/kcov --exclude-pattern=/.cargo,/usr/lib --verify "target/cov/$(basename $file)" "$file";
64
+ done
65
+ bash <(curl -s https://codecov.io/bash)
47
66
48
67
fuzz :
49
68
runs-on : ubuntu-latest
You can’t perform that action at this time.
0 commit comments