| 1 |
#!/bin/bash |
| 2 |
|
| 3 |
export PATH=$WORKSPACE/vpython/bin:$PATH |
| 4 |
g++ --version |
| 5 |
|
| 6 |
# Setup virtual Python environment |
| 7 |
\rm -Rf vpython |
| 8 |
python cxxtest/admin/virtualenv.py vpython |
| 9 |
#vpy/scripts/vpy_install |
| 10 |
vpython/bin/easy_install nose |
| 11 |
vpython/bin/easy_install unittest2 |
| 12 |
vpython/bin/easy_install ply |
| 13 |
vpython/bin/easy_install ordereddict |
| 14 |
vpython/bin/easy_install gcovr |
| 15 |
vpython/bin/easy_install pyutilib.th |
| 16 |
cd cxxtest/python |
| 17 |
../../vpython/bin/python setup.py install |
| 18 |
|
| 19 |
# Cleanup test directory |
| 20 |
cd ../test |
| 21 |
make clean |
| 22 |
cd ../.. |
| 23 |
|
| 24 |
# Run tests |
| 25 |
#export CXXTEST_GCOV_FLAGS='-fprofile-arcs -ftest-coverage' |
| 26 |
vpython/bin/nosetests --verbosity=2 --with-xunit --xunit-file=$WORKSPACE/TEST-cxxtest.xml -w $WORKSPACE/cxxtest/test |
| 27 |
|
| 28 |
# Generate code coverage |
| 29 |
#cd cxxtest |
| 30 |
#../vpython/bin/gcovr -v -r $WORKSPACE/cxxtest -x -o $WORKSPACE/cxxtest/test/coverage.xml --gcov-filter '.*#test#(\.\.|\^)#cxxtest#.*gcov' |
| 31 |
|
| 32 |
echo "DONE" |
| 33 |
|
| 34 |
# Cleanup old gcov files |
| 35 |
cd $WORKSPACE |
| 36 |
#\rm -f *.gcov cxxtest/*.gcov doc/*.gcov doc/examples/*.gcov |
| 37 |
#\rm -f *.gcno cxxtest/*.gcno doc/*.gcno doc/examples/*.gcno |
| 38 |
#\rm -f *.gcda cxxtest/*.gcda doc/*.gcda doc/examples/*.gcda |
| 39 |
cd $WORKSPACE/cxxtest/test |
| 40 |
make clean |
| 41 |
|