diff options
author | 2013-09-08 14:58:00 +0200 | |
---|---|---|
committer | 2013-09-08 14:58:00 +0200 | |
commit | 470be5db75bccb8a42b05798abd5b1000544d216 (patch) | |
tree | e097dde056d24c063a06e61f59b106871a0998c9 | |
parent | Add script to run flake checks without running the tests (diff) | |
download | identity.gentoo.org-470be5db75bccb8a42b05798abd5b1000544d216.tar.gz identity.gentoo.org-470be5db75bccb8a42b05798abd5b1000544d216.tar.bz2 identity.gentoo.org-470be5db75bccb8a42b05798abd5b1000544d216.zip |
Remove the -s arg, since we always need to define the test settings
-rwxr-xr-x | bin/runtests | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/bin/runtests b/bin/runtests index f77f005..0825325 100755 --- a/bin/runtests +++ b/bin/runtests @@ -1,8 +1,7 @@ #!/bin/bash -while getopts sdcf2 arg; do +while getopts dcf2 arg; do case ${arg} in - s) SETTINGS="--settings=okupy.tests.settings" ;; d) TDAEMON="tdaemon -t django" ;; c) COVERAGE="coverage" ;; f) FLAKE8="flake8 . --exclude=./okupy/tests/settings.py,./okupy/settings,setup.py,.virtualenv" ;; @@ -10,14 +9,16 @@ while getopts sdcf2 arg; do esac done +ARGS="--settings=okupy.tests.settings --traceback" + if [[ -n ${TDAEMON} ]]; then [[ -n ${COVERAGE} ]] && COVERAGE="-c" - ${TDAEMON} ${COVERAGE} --custom-args="${SETTINGS} ${*:${OPTIND}}" + ${TDAEMON} ${COVERAGE} --custom-args="${ARGS} ${*:${OPTIND}}" elif [[ -n ${COVERAGE} ]]; then - ${COVERAGE} run manage.py test --traceback ${SETTINGS} "${@:${OPTIND}}" + ${COVERAGE} run manage.py test ${ARGS} "${@:${OPTIND}}" ${COVERAGE} report -m else - COMMAND="python${SUFFIX} manage.py test --traceback ${SETTINGS} ${*:${OPTIND}}" + COMMAND="python${SUFFIX} manage.py test ${ARGS} ${*:${OPTIND}}" echo "Executing: $COMMAND" $COMMAND fi |