]> git.sur5r.net Git - bacula/bacula/commitdiff
regress: update base-job-test
authorEric Bollengier <eric@eb.homelinux.org>
Thu, 17 Jun 2010 07:30:59 +0000 (09:30 +0200)
committerEric Bollengier <eric@eb.homelinux.org>
Thu, 17 Jun 2010 07:30:59 +0000 (09:30 +0200)
regress/scripts/functions
regress/tests/base-job-test

index a000a7ea876bd14694ed3ae7f9923a02005f82bf..baa458649f50d4535c92a14fda355600baa8f149 100644 (file)
@@ -109,6 +109,10 @@ set_debug()
 
 print_debug()
 {
+   echo $* | grep ERROR > /dev/null
+   if test $? -eq 0; then
+     print_error="$print_error\n$*"
+   fi
    if test "$debug" -eq 1 ; then
      echo $*
    fi
@@ -317,6 +321,7 @@ end_test()
 {
    cat ${working}/bacula.*.traceback 2>/dev/null
    cat ${working}/*.bactrace 2>/dev/null
+   echo -e $print_error
    if [ $estat != 0 ] ; then
       echo " "
       echo "  !!!!! $TestName failed!!! `date +%R:%S` !!!!! "
index 6eada768e14214ea605a3c4dc07c9f1d50253221..90222eaf81f160b3be0222719f50b4a4a3a0862d 100755 (executable)
@@ -103,7 +103,13 @@ rm -rf ${cwd}/tmp/bacula-restores
 
 grep -e 'FD Bytes Written: *0' ${cwd}/tmp/log4.out > /dev/null
 if [ $? -ne 0 ]; then
-    print_debug "The first full job should have 0 byte in log4.out"
+    print_debug "ERROR: The first full job should have 0 byte in log4.out"
+    bstat=2
+fi
+
+grep -e 'Using BaseJobId(s): 1$'  ${cwd}/tmp/log4.out > /dev/null
+if [ $? -ne 0 ]; then
+    print_debug "ERROR: The first full job should use only jobid=1 as basejob"
     bstat=2
 fi