]> git.sur5r.net Git - bacula/bacula/blobdiff - regress/scripts/functions
ebl update for next-vol test
[bacula/bacula] / regress / scripts / functions
index 6ddd0570c51e944878b1df5911c82ae80c74b7f8..96095a3981a661e17e56215a9fb5c465141dbecb 100644 (file)
@@ -56,10 +56,10 @@ if test x${AUTOCHANGER} = x/dev/null ; then
 fi
 }
 
-require_faketape() 
+require_vtape() 
 {
-if test x${USE_FAKETAPE} = x ; then
-   echo "$TestName test needs the faketape driver."
+if test x${USE_VTAPE} = x ; then
+   echo "$TestName test needs the vtape driver."
    exit 1
 fi
 }
@@ -260,9 +260,21 @@ debug_wait()
   fi
 }
 
+init_slot()
+{
+   DRIVE=$1
+   SLOT=$2
+   if test -n "$DRIVE" -a -n "$SLOT"; then
+      if test ! -c $DRIVE -a ! -b $DRIVE -a x$USE_VTAPE != x ; then
+         dir=`dirname $DRIVE`
+         touch $dir/slot$SLOT
+      fi
+   fi
+}
+
 init_drive()
 {
-  if test a$USE_FAKETAPE = a; then
+  if test a$USE_VTAPE = a; then
     mt -f $1 rewind
     mt -f $1 weof
   else
@@ -282,3 +294,4 @@ fi
 . ${cwd}/config
 
 CLIENT=${HOST}-fd
+AUTOCHANGER_SCRIPT=${AUTOCHANGER_SCRIPT:-mtx-changer}