提交 f42505c0 编写于 作者: W wuzewu

update the test case run script to support specify a test case list file

上级 fda184fd
......@@ -9,7 +9,8 @@ os:
- linux
script:
- sh ./scripts/test_all_case.sh
- sh ./scripts/test_all_case.sh ./tests/tclist_all
- sh ./scripts/check_code_style.sh
notifications:
email:
......
#!/bin/bash
set -o errexit
function usage() {
echo "usage: sh $0 {test_case_list_file}"
}
if [ $# -lt 1 ]
then
usage
exit 1
fi
listfile=$1
base_path=$(cd `dirname $0`/..; pwd)
test_case_path=${base_path}/tests
export PYTHONPATH=$base_path:$PYTHONPATH
# install the require package
cd ${base_path}
pip install -r requirements.txt
cd ${test_case_path}
# only run python test case
for test_file in `ls | grep \.py`
# run all case list in the {listfile}
cd ${test_case_path}
for test_file in `cat $listfile`
do
python $test_file
python ${test_file}.py
done
test_downloader
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册