Skip to content

Commit b2004ed

Browse files
author
Stefan Reinauer
committed
fix automated coverage
git-svn-id: svn://coreboot.org/openbios/fcode-utils@112 f158a5a8-5612-0410-a976-696ce0be7e32
1 parent 085ca63 commit b2004ed

File tree

2 files changed

+30
-0
lines changed

2 files changed

+30
-0
lines changed

Makefile

+6
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@
2121
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA, 02110-1301 USA
2222
#
2323

24+
VERSION:=$(shell grep ^\#.*TOKE_VERSION < toke/toke.c |cut -f2 -d\" )
25+
2426
all:
2527
make -C toke
2628
make -C detok
@@ -51,6 +53,10 @@ tests: all
5153
cp romheaders/romheaders testsuite
5254
make -C testsuite all CygTestLogs=`pwd`/testlogs
5355

56+
# lcov required for html reports
57+
coverage:
58+
@testsuite/GenCoverage . fcode-suite-$(VERSION) "FCode suite $(VERSION)"
59+
@testsuite/GenCoverage toke toke-$(VERSION) "Toke $(VERSION)"
5460

5561
.PHONY: all clean distclean toke detok romheaders tests
5662

testsuite/GenCoverage

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#!/bin/bash
2+
3+
SRCDIR=$1
4+
DSTDIR=$2
5+
BASENAME=$DSTDIR
6+
TITLE="$3"
7+
8+
printf "Generating info file..."
9+
geninfo -t $BASENAME -o $BASENAME.info $SRCDIR 2>/dev/null
10+
printf "ok\n"
11+
12+
printf "Filtering info file..."
13+
sed -i "/stat\.h/ {
14+
N
15+
N
16+
N
17+
N
18+
d
19+
}" $BASENAME.info
20+
printf "ok\n"
21+
22+
genhtml --output-directory $DSTDIR --show-details --highlight --legend --frames --title "$TITLE" $BASENAME.info
23+
24+

0 commit comments

Comments
 (0)