加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
.jenkins.sh 1.99 KB
一键复制 编辑 原始数据 按行查看 历史
clowwindy 提交于 2015-02-05 17:07 . test more arguments
#!/bin/bash
result=0
function run_test {
printf '\e[0;36m'
echo "running test: $command $@"
printf '\e[0m'
$command "$@"
status=$?
if [ $status -ne 0 ]; then
printf '\e[0;31m'
echo "test failed: $command $@"
printf '\e[0m'
echo
result=1
else
printf '\e[0;32m'
echo OK
printf '\e[0m'
echo
fi
return 0
}
rm src/*.gc*
run_test ./autogen.sh
run_test ./configure --enable-debug
make clean
run_test make
run_test src/chinadns -h
run_test src/chinadns -V
run_test tests/test.py -a '-c chnroute.txt -l iplist.txt' -t tests/google.com
run_test tests/test.py -a '-c chnroute.txt -l iplist.txt' -t tests/facebook.com
run_test tests/test.py -a '-c chnroute.txt -s 114.114.114.114,8.8.8.8 -l iplist.txt' -t tests/google.com
run_test tests/test.py -a '-c chnroute.txt -y 0.5 -l iplist.txt' -t tests/google.com
run_test tests/test.py -a '-c chnroute.txt -b 0.0.0.0 -l iplist.txt' -t tests/google.com
run_test tests/test.py -a '-c chnroute.txt -l iplist.txt' -t tests/twitter.com
run_test tests/test.py -a '-d -c chnroute.txt -l iplist.txt' -t tests/twitter.com
run_test tests/test.py -a '-c chnroute.txt' -t tests/twitter.com
run_test tests/test.py -a '-m -c chnroute.txt' -t tests/twitter.com
run_test tests/test.py -a '-c chnroute.txt -l iplist.txt' -t tests/taobao.com
run_test tests/test.py -a '-d -c chnroute.txt -l iplist.txt' -t tests/taobao.com
run_test tests/test.py -a '-c chnroute.txt' -t tests/taobao.com
run_test tests/test.py -a '-m -c chnroute.txt' -t tests/taobao.com
run_test tests/test.py -a '-c chnroute.txt -l iplist.txt' -t tests/x_8888
run_test tests/test.py -a '-d -c chnroute.txt -l iplist.txt' -t tests/x_8888
run_test tests/test.py -a '-c chnroute.txt' -t tests/x_8888
run_test tests/test.py -a '-m -c chnroute.txt' -t tests/x_8888
gcov src/*.c
rm src/*.html
cd src && gcovr -r . --html --html-details -o index.html
gcovr -r . | grep TOTAL | rev | cut -d' ' -f 1 | rev > /tmp/chinadns-coverage
exit $result
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化