#!/bin/sh
+#
+# Copyright (C) 2000-2015 Kern Sibbald
+# License: BSD 2-Clause; see file LICENSE-FOSS
+#
+
#
# Run a simple backup of the Bacula build directory
# then restore it.
start_test
rm -rf ${cwd}/build/src/test ${cwd}/build/po/test
-mkdir ${cwd}/build/src/test
+mkdir -p ${cwd}/build/src/test
touch ${cwd}/build/src/test/test1 ${cwd}/build/src/test/test2
cat <<END_OF_DATA >$tmp/bconcmds
@output /dev/null
messages
@$out $tmp/log1.out
-label volume=TestVolume001 storage=File pool=Default
+label volume=TestVolume001 storage=File1 pool=File slot=1 drive=1
run job=$JobName yes
wait
messages
yes
wait
messages
-@$out
quit
END_OF_DATA
grep test1 $tmp/log3.out > /dev/null
if [ $? = 0 ]; then
- print_debug "Normal estimate shouldn't detect test1 file in $tmp/log3.out"
+ print_debug "ERROR: Normal estimate shouldn't detect test1 file in $tmp/log3.out"
dstat=2
fi
grep test1 $tmp/log4.out > /dev/null
if [ $? != 0 ]; then
- print_debug "Accurate=yes estimate should detect test1 file in $tmp/log4.out"
+ print_debug "ERROR: Accurate=yes estimate should detect test1 file in $tmp/log4.out"
dstat=2
fi
grep test1 $tmp/log5.out > /dev/null
if [ $? != 0 ]; then
- print_debug "Accurate estimate should detect test1 file in $tmp/log5.out"
+ print_debug "ERROR: Accurate estimate should detect test1 file in $tmp/log5.out"
dstat=2
fi
grep test1 $tmp/log6.out > /dev/null
if [ $? = 0 ]; then
- print_debug "Accurate=no estimate shouldn't detect test1 file in $tmp/log6.out"
+ print_debug "ERROR: Accurate=no estimate shouldn't detect test1 file in $tmp/log6.out"
dstat=2
fi
-check_for_zombie_jobs storage=File
+check_for_zombie_jobs storage=File1
stop_bacula
end_test