pocketpy/run_tests.sh
BLUELOVETH 162c597093 Revert "test benchmarks"
This reverts commit f25b99cbbd2cca40c24f94938e17bcf44068adef.
2023-08-10 15:12:35 +08:00

19 lines
447 B
Bash

python3 prebuild.py
SRC=$(find src/ -name "*.cpp")
clang++ -std=c++17 --coverage -O1 -stdlib=libc++ -Wfatal-errors -o main src2/main.cpp $SRC -Iinclude -ldl
python3 scripts/run_tests.py
# if prev error exit
if [ $? -ne 0 ]; then
exit 1
fi
rm -rf .coverage
mkdir .coverage
rm pocketpy_c.gcno
UNITS=$(find ./ -name "*.gcno")
llvm-cov-15 gcov ${UNITS} -r -s include/ -r -s src/ >> .coverage/coverage.txt
mv *.gcov .coverage
rm *.gcda
rm *.gcno