tests.sh 499 Bytes
Newer Older
1
#!/bin/sh
2
3
set -e

4
5
6
export SYNNEFO_SETTINGS_DIR=/tmp/snf-test-settings

SNF_MANAGE=$(which snf-manage) ||
7
	{ echo "Cannot find snf-manage in $PATH" 1>&2; exit 1; }
8

9
APPS="api db logic plankton quotas vmapi im quotaholder_app helpdesk"
10
TEST="$(which snf-manage) test $APPS --traceback --settings=synnefo.settings.test"
11
12
13
14
15

if coverage >/dev/null 2>&1; then
  coverage run $TEST
  coverage report --include=snf-*
else
16
  echo "WARNING: Cannot find coverage in path, skipping coverage tests" 1>&2
17
18
  $TEST
fi