]> git.sur5r.net Git - bacula/bacula/blob - regress/tests/lzo-test
Fix regression minor scripting problems
[bacula/bacula] / regress / tests / lzo-test
1 #!/bin/sh
2 #
3 # Copyright (C) 2000-2015 Kern Sibbald
4 # License: BSD 2-Clause; see file LICENSE-FOSS
5 #
6
7 #
8 # Run a simple backup of the Bacula build directory using the compressed option
9 #   then restore it.
10 #
11 TestName="lzo-test"
12 JobName=lzo
13 . scripts/functions
14
15 scripts/cleanup
16 scripts/copy-test-confs
17 echo "${cwd}/build" >${cwd}/tmp/file-list
18
19 start_test
20       
21 cat <<END_OF_DATA >${cwd}/tmp/bconcmds
22 @output /dev/null
23 messages
24 @$out ${cwd}/tmp/log1.out
25 status all
26 status all
27 messages
28 label storage=File volume=TestVolume001
29 run job=LZOTest storage=File yes
30 wait
31 messages
32 @# 
33 @# now do a restore
34 @#
35 @$out ${cwd}/tmp/log2.out
36 restore where=${cwd}/tmp/bacula-restores select storage=File
37 unmark *
38 mark *
39 done
40 yes
41 wait
42 messages
43 quit
44 END_OF_DATA
45
46 run_bacula
47 check_for_zombie_jobs storage=File
48 stop_bacula
49
50 check_two_logs
51 check_restore_diff
52 grep " Software Compression" ${cwd}/tmp/log1.out | grep "%" 2>&1 1>/dev/null
53 if [ $? != 0 ] ; then
54    echo "  !!!!! No compression !!!!!"
55    bstat=1
56 fi
57 end_test