run_tests.sh 769 Bytes
Newer Older
1
2
#!/bin/bash

3
ROUGE="\\033[1;31m"
4

5
6
7
8
cd $CI_PROJECT_DIR

export PYTHONPATH=${CI_PROJECT_DIR}/build/lib.macosx-10.6-intel-2.7

9
10
# Performs the unit tests
cd Tests/UnitTests
eric pellegrini's avatar
eric pellegrini committed
11
/Library/Frameworks/Python.framework/Versions/2.7/bin/nosetests --verbosity=3 -P .
12
# Exit now if unable to run tests
Remi Perenon's avatar
Remi Perenon committed
13
status=$?
Remi Perenon's avatar
Remi Perenon committed
14
if [ $status -ne 0 ]; then
15
	echo -e "$ROUGE""One or several unit tests failed"
16
	exit $status
17
fi
18
19
cd ../..

20
# Performs the functional tests
21
cd Tests/FunctionalTests/Jobs
22
rm -rf Test_*
23
/Library/Frameworks/Python.framework/Versions/2.7/bin/python BuildJobTests.py
24
/Library/Frameworks/Python.framework/Versions/2.7/bin/nosetests --verbosity=3 --exe Test_*.py
Remi Perenon's avatar
Remi Perenon committed
25

Remi Perenon's avatar
Remi Perenon committed
26
status=$?
Remi Perenon's avatar
Remi Perenon committed
27
if [ $status -ne 0 ]; then
28
	echo -e "$ROUGE""One or several functional tests failed"
29
	exit $status
30
fi
Remi Perenon's avatar
Remi Perenon committed
31
32

exit 0