TestName="restore2-by-file-test"
JobName=restore2byfile
. scripts/functions
-set_debug 0
+copy_test_confs
-cwd=`pwd`
-scripts/copy-test-confs
-scripts/cleanup
-echo "${cwd}/build" >/tmp/file-list
-sed s%\^%${cwd}% ${cwd}/scripts/flist >${cwd}/tmp/restore2-list
+echo "${cwd}/build" >${cwd}/tmp/file-list
+sed s%\^%${cwd}% ${cwd}/scripts/flist | sort | uniq >${cwd}/tmp/restore2-list
change_jobname CompressedTest $JobName
start_test
-cat <<END_OF_DATA >tmp/bconcmds
+cat <<END_OF_DATA >${cwd}/tmp/bconcmds
@output /dev/null
messages
-@$out tmp/log1.out
+@$out ${cwd}/tmp/log1.out
label storage=File volume=TestVolume001
run job=$JobName yes
wait
@#
@# now do a restore
@#
-@$out tmp/log2.out
+@$out ${cwd}/tmp/log2.out
restore where=${cwd}/tmp/bacula-restores storage=File file=<${cwd}/tmp/restore2-list
yes
wait