Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' of git+ssh://scm.gforge.inria.fr//gitroot/simgrid/simgrid
authorFrederic Suter <frederic.suter@cc.in2p3.fr>
Wed, 16 Mar 2016 12:05:12 +0000 (13:05 +0100)
committerFrederic Suter <frederic.suter@cc.in2p3.fr>
Wed, 16 Mar 2016 12:11:19 +0000 (13:11 +0100)
teshsuite/msg/host_on_off_processes/host_on_off_processes.c
tools/jenkins/Coverage.sh [new file with mode: 0755]
tools/jenkins/DynamicAnalysis.sh

index 537e596..0aa4cbf 100644 (file)
@@ -221,7 +221,7 @@ int main(int argc, char *argv[])
 
   unsigned int iter;
   char *groups;
-  xbt_dynar_t s_tests = xbt_str_split(argv[3], ",");
+  xbt_dynar_t s_tests = xbt_str_split(argv[2], ",");
   int tmp_test = 0;
   tests = xbt_dynar_new(sizeof(int), NULL);
   xbt_dynar_foreach(s_tests, iter, groups) {
diff --git a/tools/jenkins/Coverage.sh b/tools/jenkins/Coverage.sh
new file mode 100755 (executable)
index 0000000..d40f9d0
--- /dev/null
@@ -0,0 +1,63 @@
+#!/bin/sh
+
+set -e
+
+die() {
+    echo "$@"
+    exit 1
+}
+
+do_cleanup() {
+  for d in "$WORKSPACE/build"
+  do
+    if [ -d "$d" ]
+    then
+      rm -rf "$d" || die "Could not remote $d"
+    fi
+  done
+  find $WORKSPACE -name "memcheck_test_*.memcheck" -exec rm {} \;
+}
+
+### Check the node installation
+
+for pkg in xsltproc gcovr
+do
+   if command -v $pkg
+   then 
+      echo "$pkg is installed. Good."
+   else 
+      die "please install $pkg before proceeding" 
+   fi
+done
+
+###¬†Cleanup previous runs
+
+! [ -z "$WORKSPACE" ] || die "No WORKSPACE"
+[ -d "$WORKSPACE" ] || die "WORKSPACE ($WORKSPACE) does not exist"
+
+do_cleanup
+
+for d in "$WORKSPACE/build"
+do
+  mkdir "$d" || die "Could not create $d"
+done
+
+cd $WORKSPACE/build
+
+ctest -D ExperimentalStart || true
+
+cmake -Denable_documentation=OFF -Denable_lua=ON -Denable_java=ON \
+      -Denable_compile_optimizations=OFF -Denable_compile_warnings=ON \
+      -Denable_jedule=ON -Denable_mallocators=ON \
+      -Denable_smpi=ON -Denable_smpi_MPICH3_testsuite=ON -Denable_model-checking=ON \
+      -Denable_memcheck=OFF -Denable_memcheck_xml=OFF -Denable_smpi_ISP_testsuite=ON -Denable_coverage=ON $WORKSPACE
+
+ctest -D ExperimentalBuild -V
+ctest -D ExperimentalTest -E liveness || true
+ctest -D ExperimentalCoverage || true
+
+if [ -f Testing/TAG ] ; then
+   gcovr -r .. --xml-pretty -e teshsuite.* -u -o $WORKSPACE/xml_coverage.xml
+   xsltproc $WORKSPACE/tools/jenkins/ctest2junit.xsl Testing/`head -n 1 < Testing/TAG`/Test.xml > CTestResults_memcheck.xml
+   mv CTestResults_memcheck.xml $WORKSPACE
+fi
index cd9b2b4..fae9f40 100755 (executable)
@@ -20,7 +20,7 @@ do_cleanup() {
 
 ### Check the node installation
 
-for pkg in xsltproc valgrind gcovr
+for pkg in valgrind
 do
    if command -v $pkg
    then 
@@ -62,21 +62,3 @@ if [ -f Testing/TAG ] ; then
    mv Testing/`head -n 1 < Testing/TAG`/DynamicAnalysis.xml  $WORKSPACE
 fi
 
-make clean
-ctest -D ExperimentalStart || true
-
-cmake -Denable_documentation=OFF -Denable_lua=ON -Denable_java=ON \
-      -Denable_compile_optimizations=OFF -Denable_compile_warnings=ON \
-      -Denable_jedule=ON -Denable_mallocators=ON \
-      -Denable_smpi=ON -Denable_smpi_MPICH3_testsuite=ON -Denable_model-checking=ON \
-      -Denable_memcheck=OFF -Denable_memcheck_xml=OFF -Denable_smpi_ISP_testsuite=ON -Denable_coverage=ON $WORKSPACE
-
-ctest -D ExperimentalBuild -V
-ctest -D ExperimentalTest -E liveness || true
-ctest -D ExperimentalCoverage || true
-
-if [ -f Testing/TAG ] ; then
-   gcovr -r .. --xml-pretty -e teshsuite.* -u -o $WORKSPACE/xml_coverage.xml
-   xsltproc $WORKSPACE/tools/jenkins/ctest2junit.xsl Testing/`head -n 1 < Testing/TAG`/Test.xml > CTestResults_memcheck.xml
-   mv CTestResults_memcheck.xml $WORKSPACE
-fi