about summary refs log tree commit diff homepage
diff options
context:
space:
mode:
authorCristian Cadar <c.cadar@imperial.ac.uk>2016-12-18 17:57:01 +0000
committerGitHub <noreply@github.com>2016-12-18 17:57:01 +0000
commitba009ba1f66396f0951c703e6a68e393d01be7af (patch)
tree38a6ebc9bc287b9b44f1bc65ab8c9349c23ff444
parente056aa4e0bd25a021f5385904bf6507ac8ca5e21 (diff)
parentfd7d94baa3e5a8462d70e975da0cf09d435c0776 (diff)
downloadklee-ba009ba1f66396f0951c703e6a68e393d01be7af.tar.gz
Merge pull request #549 from delcypher/fix_travisci_errexit
Fixes and clean ups in the TravisCI scripts
-rwxr-xr-x.travis/klee.sh32
1 files changed, 9 insertions, 23 deletions
diff --git a/.travis/klee.sh b/.travis/klee.sh
index 64bfcb67..e1adc6bc 100755
--- a/.travis/klee.sh
+++ b/.travis/klee.sh
@@ -146,7 +146,8 @@ if [ "X${USE_CMAKE}" == "X1" ]; then
     ${KLEE_ASSERTS_OPTION} \
     -DENABLE_TESTS=TRUE \
     -DLIT_ARGS="-v" \
-    ${KLEE_SRC} && make
+    ${KLEE_SRC}
+  make
 else
   # Build KLEE
   # Note: ENABLE_SHARED=0 is required because llvm-2.9 is incorectly packaged
@@ -161,22 +162,18 @@ else
               ${KLEE_METASMT_CONFIGURE_OPTION} \
               ${KLEE_UCLIBC_CONFIGURE_OPTION} \
               ${TCMALLOC_OPTION} \
-              CXXFLAGS="${COVERAGE_FLAGS}" \
-              && make DISABLE_ASSERTIONS=${DISABLE_ASSERTIONS} \
-                      ENABLE_OPTIMIZED=${ENABLE_OPTIMIZED} \
-                      ENABLE_SHARED=0
+              CXXFLAGS="${COVERAGE_FLAGS}"
+  make \
+    DISABLE_ASSERTIONS=${DISABLE_ASSERTIONS} \
+    ENABLE_OPTIMIZED=${ENABLE_OPTIMIZED} \
+    ENABLE_SHARED=0
 fi
-###############################################################################
-# Testing
-###############################################################################
-set +e # We want to let all the tests run before we exit
 
 ###############################################################################
 # Unit tests
 ###############################################################################
 if [ "X${USE_CMAKE}" == "X1" ]; then
   make unittests
-  RETURN="$?"
 else
   # The unittests makefile doesn't seem to have been packaged so get it from SVN
   sudo mkdir -p /usr/lib/llvm-${LLVM_VERSION}/build/unittests/
@@ -188,7 +185,6 @@ else
       DISABLE_ASSERTIONS=${DISABLE_ASSERTIONS} \
       ENABLE_OPTIMIZED=${ENABLE_OPTIMIZED} \
       ENABLE_SHARED=0
-  RETURN="$?"
 fi
 
 ###############################################################################
@@ -196,7 +192,6 @@ fi
 ###############################################################################
 if [ "X${USE_CMAKE}" == "X1" ]; then
   make integrationtests
-  RETURN="${RETURN}$?"
 else
   # Note can't use ``make check`` because llvm-lit is not available
   cd test
@@ -205,10 +200,8 @@ else
       DISABLE_ASSERTIONS=${DISABLE_ASSERTIONS} \
       ENABLE_OPTIMIZED=${ENABLE_OPTIMIZED} \
       ENABLE_SHARED=0
-
-  set +e # We want to let all the tests run before we exit
-  lit -v .
-  RETURN="${RETURN}$?"
+  cd ../
+  lit -v test/
 fi
 
 #generate and upload coverage if COVERAGE is set
@@ -242,10 +235,3 @@ if [ ${COVERAGE} -eq 1 ]; then
     tar -zcvf coverage.tar.gz coverage/
     curl --form "file=@coverage.tar.gz" -u ${USER}:${PASSWORD} ${COVERAGE_SERVER}
 fi
-###############################################################################
-# Result
-###############################################################################
-if [ "${RETURN}" != "00" ]; then
-    echo "Running tests failed"
-    exit 1
-fi