run_tests: add --help properly
This commit is contained in:
parent
4f0847bcf8
commit
e884a5f71c
1 changed files with 15 additions and 16 deletions
31
run_tests
31
run_tests
|
|
@ -1,21 +1,5 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
if [ "$1" == "--help" ]; then
|
|
||||||
echo "$(basename $0) [--basedir <basedir>] [--install] <optional list of tests in form file:func>"
|
|
||||||
echo ""
|
|
||||||
echo " --basedir <basedir> path to runtime directory like the optino to install_gadget.py"
|
|
||||||
echo " --install run install_gadget.py, useful with --basedir"
|
|
||||||
echo " --report <messages|all> which logs to dump to stdout after a test"
|
|
||||||
echo " --quiet suppress vim's stdout"
|
|
||||||
echo "e.g.: "
|
|
||||||
echo " - run all tests: $0"
|
|
||||||
echo " - run specific tests script: $0 signature_help.test.vim"
|
|
||||||
echo " - run specific tests fun: $0 signature_help.test.vim:Test_signatures_TopLine\(\)"
|
|
||||||
echo " - run all tests in a clean env: $0 --basedir \$(mktemp -d) --install"
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
BASEDIR=$(dirname $0)
|
BASEDIR=$(dirname $0)
|
||||||
INSTALL=0
|
INSTALL=0
|
||||||
RUN_VIM="vim -N --clean --not-a-term"
|
RUN_VIM="vim -N --clean --not-a-term"
|
||||||
|
|
@ -59,6 +43,21 @@ while [ -n "$1" ]; do
|
||||||
shift
|
shift
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
|
"--help")
|
||||||
|
shift
|
||||||
|
echo "$(basename $0) [--basedir <basedir>] [--report output] [--quiet] [--install] <optional list of tests in form file:func>"
|
||||||
|
echo ""
|
||||||
|
echo " --basedir <basedir> path to runtime directory like the optino to install_gadget.py"
|
||||||
|
echo " --install run install_gadget.py, useful with --basedir"
|
||||||
|
echo " --report <messages|all> which logs to dump to stdout after a test"
|
||||||
|
echo " --quiet suppress vim's stdout"
|
||||||
|
echo "e.g.: "
|
||||||
|
echo " - run all tests: $0"
|
||||||
|
echo " - run specific tests script: $0 signature_help.test.vim"
|
||||||
|
echo " - run specific tests fun: $0 signature_help.test.vim:Test_signatures_TopLine\(\)"
|
||||||
|
echo " - run all tests in a clean env: $0 --basedir \$(mktemp -d) --install"
|
||||||
|
exit 0
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
break
|
break
|
||||||
;;
|
;;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue