Skip to content

Commit

Permalink
ST: Support fast utest and coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
winlinvip committed Apr 25, 2021
1 parent 8400115 commit d1ac9da
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions trunk/3rdparty/st-srs/auto/fast.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/bin/bash

IS_LINUX=yes
uname -s|grep Darwin >/dev/null && IS_DARWIN=yes && IS_LINUX=no
echo "IS_LINUX: $IS_LINUX, IS_DARWIN: $IS_DARWIN"

echo "Clean gcda files"
rm -f ./obj/*.gcda

echo "Build and run utest"
if [[ $IS_DARWIN == yes ]]; then
make darwin-debug-gcov && ./obj/st_utest
else
make linux-debug-gcov && ./obj/st_utest
fi

echo "Generating coverage"
mkdir -p coverage &&
gcovr -r . -e LINUX -e DARWIN -e examples --html --html-details -o coverage/st.html &&
echo "Coverage report at coverage/st.html" &&
open coverage/st.html

0 comments on commit d1ac9da

Please sign in to comment.