Fix: check if test plan exist before running them
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Mon, 16 Feb 2015 15:57:41 +0000 (10:57 -0500)
committerJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Mon, 16 Feb 2015 15:57:41 +0000 (10:57 -0500)
lttng-ust/lttng-ust-master.sh
lttng-ust/lttng-ust-stable-2.5.sh
lttng-ust/lttng-ust-stable-2.6.sh

index f792c175bf45d86b2b0688f21966aed249a7d291..5e1b6446a2846205f797c9ac399e6e116b310df8 100755 (executable)
@@ -87,7 +87,12 @@ mkdir -p $WORKSPACE/tap/unit
 
 cd $BUILD_PATH/tests
 
-prove --merge --exec '' - < $BUILD_PATH/tests/unit_tests --archive $WORKSPACE/tap/unit/ || true
+if [ -e $BUILD_PATH/tests/unit_tests ]; then
+       prove --merge --exec '' - < $BUILD_PATH/tests/unit_tests --archive $WORKSPACE/tap/unit/ || true
+else
+       echo "Test file:$BUILD_PATH/tests/unit_tests missing"
+       exit 1
+fi
 
 # TAP plugin is having a hard time with .yml files.
 rm -f $WORKSPACE/tap/unit/meta.yml
index 3d52a4965c1e03e4ab9a451204d5d2c9bad6dddf..3ef2ddfce56f57521d5b56541ac4fcfd686ef6ab 100755 (executable)
@@ -43,7 +43,12 @@ mkdir -p $WORKSPACE/tap/unit
 
 cd $WORKSPACE/tests
 
-prove --merge --exec '' - < $WORKSPACE/tests/unit_tests --archive $WORKSPACE/tap/unit/ || true
+if [ -e $BUILD_PATH/tests/unit_tests ]; then
+       prove --merge --exec '' - < $BUILD_PATH/tests/unit_tests --archive $WORKSPACE/tap/unit/ || true
+else
+       echo "Test file:$BUILD_PATH/tests/unit_tests missing"
+       exit 1
+fi
 
 # TAP plugin is having a hard time with .yml files.
 rm -f $WORKSPACE/tap/unit/meta.yml
index fb1fec4c6d9678006afc31046f5426491e9bb5b2..88a6edb3e10e48ed7a31f7d46a3f73c5b3f74f1c 100755 (executable)
@@ -83,7 +83,12 @@ mkdir -p $WORKSPACE/tap/unit
 
 cd $BUILD_PATH/tests
 
-prove --merge --exec '' - < $BUILD_PATH/tests/unit_tests --archive $WORKSPACE/tap/unit/ || true
+if [ -e $BUILD_PATH/tests/unit_tests ]; then
+       prove --merge --exec '' - < $BUILD_PATH/tests/unit_tests --archive $WORKSPACE/tap/unit/ || true
+else
+       echo "Test file:$BUILD_PATH/tests/unit_tests missing"
+       exit 1
+fi
 
 # TAP plugin is having a hard time with .yml files.
 rm -f $WORKSPACE/tap/unit/meta.yml
This page took 0.073919 seconds and 4 git commands to generate.