]> git.sur5r.net Git - bacula/bacula/commitdiff
regress: raise an error if we don t have two "list jobs"
authorEric Bollengier <eric@eb.homelinux.org>
Mon, 2 Aug 2010 07:50:49 +0000 (09:50 +0200)
committerEric Bollengier <eric@eb.homelinux.org>
Mon, 2 Aug 2010 14:54:00 +0000 (16:54 +0200)
regress/scripts/functions.pm

index 5c5258fb1db0c43a08825773e0ca3314cf1ed070..9fb4416cde66a1314292254bcbf22ad8e8b5d525 100644 (file)
@@ -37,12 +37,14 @@ package scripts::functions;
 # perl -Mscripts::functions -e '' script
 use Exporter;
 our @ISA = qw(Exporter);
-our @EXPORT =  qw(update_some_files create_many_files check_multiple_copies
-                  update_client $HOST $BASEPORT add_to_backup_list check_volume_size
-                  create_many_dirs cleanup start_bacula stop_bacula get_resource
-                  set_maximum_concurrent_jobs get_time add_attribute check_prune_list
-                  check_min_volume_size check_max_volume_size $estat $bstat $rstat $zstat
-                  $cwd $bin $scripts $conf $rscripts $tmp $working extract_resource
+
+our @EXPORT = qw(update_some_files create_many_files check_multiple_copies
+                  update_client $HOST $BASEPORT add_to_backup_list
+                  check_volume_size create_many_dirs cleanup start_bacula
+                  stop_bacula get_resource set_maximum_concurrent_jobs get_time
+                  add_attribute check_prune_list check_min_volume_size
+                  check_max_volume_size $estat $bstat $rstat $zstat $cwd $bin
+                  $scripts $conf $rscripts $tmp $working extract_resource
                   $db_name $db_user $db_password $src $tmpsrc);
 
 
@@ -480,6 +482,10 @@ sub check_prune_list
             exit 1;
         }
     }
+    if ($nb_list_job != 2) {
+        print "ERROR: in $f, not enough 'list jobs'\n";
+        exit 1;
+    }
     exit 0;
 }