aboutsummaryrefslogtreecommitdiffstats
path: root/run_unit_tests.sh
diff options
context:
space:
mode:
Diffstat (limited to 'run_unit_tests.sh')
-rwxr-xr-xrun_unit_tests.sh25
1 files changed, 25 insertions, 0 deletions
diff --git a/run_unit_tests.sh b/run_unit_tests.sh
new file mode 100755
index 000000000..a37cd3d98
--- /dev/null
+++ b/run_unit_tests.sh
@@ -0,0 +1,25 @@
+#!/bin/bash
+set -o errexit
+set -o pipefail
+
+echo "Running unit tests..."
+cd .
+
+# start vitual env
+virtualenv ./functest_venv
+source ./functest_venv/bin/activate
+
+# install python packages
+easy_install -U setuptools
+easy_install -U pip
+pip install -r docker/requirements.pip
+pip install -e .
+
+# unit tests
+nosetests --with-xunit \
+ --with-coverage \
+ --cover-package=functest\
+ --cover-xml \
+ unit_tests
+
+deactivate