X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fceph%2Fsrc%2Fceph-detect-init%2Frun-tox.sh;fp=src%2Fceph%2Fsrc%2Fceph-detect-init%2Frun-tox.sh;h=9736dc400598b23f184e58db6efc527b2aadf9a0;hb=812ff6ca9fcd3e629e49d4328905f33eee8ca3f5;hp=0000000000000000000000000000000000000000;hpb=15280273faafb77777eab341909a3f495cf248d9;p=stor4nfv.git diff --git a/src/ceph/src/ceph-detect-init/run-tox.sh b/src/ceph/src/ceph-detect-init/run-tox.sh new file mode 100755 index 0000000..9736dc4 --- /dev/null +++ b/src/ceph/src/ceph-detect-init/run-tox.sh @@ -0,0 +1,31 @@ +#!/bin/bash +# +# Copyright (C) 2015 SUSE LINUX GmbH +# Copyright (C) 2016 +# +# Author: Owen Synge +# Author: Loic Dachary +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU Library Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Library Public License for more details. +# + +# run from the ceph-detect-init directory or from its parent +: ${CEPH_DETECT_INIT_VIRTUALENV:=/tmp/ceph-detect-init-virtualenv} +test -d ceph-detect-init && cd ceph-detect-init + +if [ -e tox.ini ]; then + TOX_PATH=`readlink -f tox.ini` +else + TOX_PATH=`readlink -f $(dirname $0)/tox.ini` +fi + +source ${CEPH_DETECT_INIT_VIRTUALENV}/bin/activate +tox -c ${TOX_PATH}