From ea5efce7b1a3aadcb78b72284740583d40689d6f Mon Sep 17 00:00:00 2001 From: ashishk1994 Date: Sat, 22 Apr 2017 22:10:31 +0530 Subject: Tox utility to run unit tests MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Now run_unit_tests.sh only calls tox to allow merging. It can be safely deleted as soon as the related jjob is updated. It also removes test_logging.ini. Co-Authored-By: Cédric Ollivier Change-Id: I934f4ac739d99d0cb29bea8c6aac6d6780b30901 Signed-off-by: ashishk1994 Signed-off-by: Cédric Ollivier --- run_unit_tests.sh | 39 +-------------------------------------- 1 file changed, 1 insertion(+), 38 deletions(-) (limited to 'run_unit_tests.sh') diff --git a/run_unit_tests.sh b/run_unit_tests.sh index 3eb2cda8..31a95f48 100755 --- a/run_unit_tests.sh +++ b/run_unit_tests.sh @@ -1,42 +1,5 @@ #!/bin/bash -set -o errexit -set -o pipefail -# Either Workspace is set (CI) -if [ -z $WORKSPACE ] -then - WORKSPACE=`pwd` -fi - - -# *************** -# Run unit tests -# *************** -echo "Running unit tests..." - -sudo apt-get install -y build-essential python-dev python-pip -sudo pip install virtualenv==15.1.0 - -# start vitual env -virtualenv $WORKSPACE/functest_venv -source $WORKSPACE/functest_venv/bin/activate - -# install python packages -pip install --upgrade pip -pip install -r $WORKSPACE/requirements.txt -pip install -r $WORKSPACE/test-requirements.txt -pip install $WORKSPACE - -nosetests --with-xunit \ - --with-coverage \ - --cover-tests \ - --cover-package=functest \ - --cover-xml \ - --cover-html \ - --log-config=$(pwd)/functest/tests/unit/test_logging.ini \ - functest/tests/unit -rc=$? - -deactivate +tox exit $rc -- cgit 1.2.3-korg