# Run a simple backup (with encryption) of the Bacula build directory
# then verify the signatures.
#
-TestName="data-encrypt-test"
+TestName="sparse-encrypt-test"
JobName=Crypto
. scripts/functions
set_debug 1
run job=$JobName yes
wait
messages
+list volumes
@#
@# now do a restore
@#
check_for_zombie_jobs storage=File
stop_bacula
+size=`du ${cwd}/tmp/bacula-restores/${cwd}/build/src/tools/gigaslam.gif | cut -f 1`
+if [ $size -gt 120 ]; then
+ echo "========== restored sparse file: gigaslam.gif too big ========="
+ echo " size is ${size}K it should be 120K"
+fi
+
check_two_logs
check_restore_diff
end_test