From cde60dd63524382128e113f0f54a12b859d78034 Mon Sep 17 00:00:00 2001 From: Eric Bollengier Date: Mon, 13 Dec 2010 15:17:41 +0100 Subject: [PATCH] regress: Add test having fileset without md5 --- regress/tests/no-chksum-test | 85 ++++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100755 regress/tests/no-chksum-test diff --git a/regress/tests/no-chksum-test b/regress/tests/no-chksum-test new file mode 100755 index 0000000000..faedfd5b7a --- /dev/null +++ b/regress/tests/no-chksum-test @@ -0,0 +1,85 @@ +#!/bin/sh +# +# Run a simple backup of the Bacula build directory without +# md5 signature then restore it. +# +TestName="no-chksum-test" +JobName=backup +. scripts/functions + +scripts/cleanup +scripts/copy-confs + +# +# Zap out any schedule in default conf file so that +# it doesn't start during our test +# +outf="$tmp/sed_tmp" +echo "s% Schedule =%# Schedule =%g" > $outf +echo "s% signature =%# signature =%g" >> $outf +cp $scripts/bacula-dir.conf $tmp/1 +sed -f $outf $tmp/1 >$scripts/bacula-dir.conf + +change_jobname BackupClient1 $JobName +start_test + +cat <$tmp/bconcmds +@$out /dev/null +messages +@$out $tmp/log1.out +label volume=TestVolume001 storage=File pool=File +END_OF_DATA + +run_bacula + +cat <$tmp/bconcmds +@$out $tmp/log1.out +run job=$JobName yes +wait +messages +quit +END_OF_DATA + +run_bconsole + +# +# Now do a second backup after making a few changes +# +touch ${cwd}/build/po/fr.po +# + +run_bconsole + +dd if=/dev/zero of=$cwd/build/bigfile count=500000 > /dev/null + +run_bconsole + +rm -f $cwd/build/bigfile + +cat <$tmp/bconcmds +@$out /dev/null +messages +@$out $tmp/log1.out +@# don't restore the bigfile, and try to see if it reads the whole volume +list files jobid=3 +delete jobid=3 +@# +@# now do a restore +@# +@$out $tmp/log2.out +setdebug level=150 trace=1 storage=File +restore where=$tmp/bacula-restores select all done +yes +wait +messages +quit +END_OF_DATA + +run_bconsole + +check_for_zombie_jobs storage=File +stop_bacula + +check_two_logs +check_restore_diff +end_test -- 2.39.5