]> git.sur5r.net Git - bacula/bacula/blobdiff - regress/tests/weird-files-test
Update
[bacula/bacula] / regress / tests / weird-files-test
index bac826fb662b795e44472b7176bf7bd5aea261a4..dbd88e00af9ae883e75215b3195ce2055680aae1 100755 (executable)
@@ -6,7 +6,6 @@
 TestName="weird-files-test"
 JobName=wierd-files
 . scripts/functions
-set_debug 0
 
 if test ! -d weird-files ; then
    echo " "
@@ -15,8 +14,8 @@ if test ! -d weird-files ; then
 fi
 
 cwd=`pwd`
-scripts/copy-test-confs
 scripts/cleanup
+scripts/copy-test-confs
 change_jobname NightlySave $JobName
 #
 # Note, we save the weird-files directory twice on purpose
@@ -24,8 +23,13 @@ change_jobname NightlySave $JobName
 #  that are only saved once.  In 1.33, Bacula now deals
 #  with this situation.
 #
-echo "${cwd}/weird-files" >/tmp/file-list
-echo "${cwd}/weird-files" >>/tmp/file-list
+echo "${cwd}/weird-files" >${cwd}/tmp/file-list
+echo "${cwd}/weird-files" >>${cwd}/tmp/file-list
+
+# Create a Unix domain socket (sock-file)
+cd weird-files
+perl socket.pl
+cd ..
 
 start_test
 
@@ -57,6 +61,10 @@ END_OF_DATA
 run_bacula
 check_for_zombie_jobs storage=File 
 stop_bacula
+# Note, the Unix domain socket (sock-file) is not restored
+#  by Bacula so we delete it for the diffs
+rm -f weird-files/sock-file
+touch weird-files tmp/bacula-restores${cwd}/weird-files
 
 ${cwd}/bin/testls weird-files | sort >${cwd}/tmp/original
 cd tmp/bacula-restores${cwd}
@@ -64,6 +72,7 @@ ${cwd}/bin/testls weird-files | sort >${cwd}/tmp/restored
 cd ${cwd}
 
 check_two_logs
-diff ${cwd}/tmp/original ${cwd}/tmp/restored 2>&1 >/dev/null
+#diff ${cwd}/tmp/original ${cwd}/tmp/restored 2>&1 >/dev/null
+diff ${cwd}/tmp/original ${cwd}/tmp/restored                
 dstat=$?
 end_test