From 4472aafbe0d9437ffa2739fb3de94778dfe9250b Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Sat, 28 Dec 2013 11:08:16 +0200 Subject: [PATCH] tests: Generate a combined code coverage report This combines coverage from all three separate reports into a single report. Signed-hostap: Jouni Malinen --- tests/hwsim/vm/vm-run.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/hwsim/vm/vm-run.sh b/tests/hwsim/vm/vm-run.sh index 0f556decb..a2b9187f1 100755 --- a/tests/hwsim/vm/vm-run.sh +++ b/tests/hwsim/vm/vm-run.sh @@ -130,6 +130,15 @@ if [ $CODECOV = "yes" ]; then genhtml -t "hostapd/hlr_auc_gw (AS) hwsim test run $DATE" lcov.info --output-directory $LOGDIR/lcov-hostapd-as >> lcov.log 2>&1 mv lcov.info lcov.log $LOGDIR/lcov-hostapd-as + echo "Generating combined code coverage report" + mkdir $LOGDIR/lcov-combined + for i in wpa_supplicant hostapd hostapd-as; do + sed s%SF:/tmp/logs/alt-[^/]*/%SF:/tmp/logs/alt-wpa_supplicant/% < $LOGDIR/lcov-$i/lcov.info > $LOGDIR/lcov-combined/$i.info + done + cd $LOGDIR/lcov-combined + lcov -a wpa_supplicant.info -a hostapd.info -a hostapd-as.info -o combined.info > lcov.log 2>&1 + genhtml -t "wpa_supplicant/hostapd combined for hwsim test run $DATE" combined.info --output-directory . >> lcov.log 2>&1 + cd $DIR rm -r /tmp/logs/alt-wpa_supplicant rm -r /tmp/logs/alt-hostapd @@ -145,4 +154,5 @@ if [ $CODECOV = "yes" ]; then echo "wpa_supplicant: file://$LOGDIR/lcov-wpa_supplicant/index.html" echo "hostapd: file://$LOGDIR/lcov-hostapd/index.html" echo "hostapd/hlr_auc_gw (AS): file://$LOGDIR/lcov-hostapd-as/index.html" + echo "combined: file://$LOGDIR/lcov-combined/index.html" fi