Skip to content

Commit

Permalink
systemtests: remove redundant bareos stops
Browse files Browse the repository at this point in the history
Since the `end_test` function automatically shuts down bareos when it is 
a single testrunner, stoping bareos before makes tests try to shutdown 
bareos twice which may be causing some sporadic errors
tls
  • Loading branch information
alaaeddineelamri authored and pstorz committed Sep 19, 2022
1 parent 48cd7ac commit 2288374
Show file tree
Hide file tree
Showing 34 changed files with 1 addition and 47 deletions.
1 change: 0 additions & 1 deletion systemtests/tests/acl/testrunner
Expand Up @@ -57,7 +57,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs

Expand Down
2 changes: 0 additions & 2 deletions systemtests/tests/bareos-acl/testrunner
Expand Up @@ -42,6 +42,4 @@ grep -q "status conf: is an invalid command" ${logdir}/acl-status.log || \
grep -q "eprecated configuration settings detected" ${logdir}/acl-status-conf.log || \
set_error "acl-status-conf.log"

stop_bareos

end_test
2 changes: 0 additions & 2 deletions systemtests/tests/bscan-bextract-bls-bcopy/testrunner
Expand Up @@ -163,8 +163,6 @@ run_bconsole "$tmp/bconcmds2"

check_for_zombie_jobs storage=File

stop_bareos

check_two_logs
check_restore_diff "${BackupDirectory}"
end_test
1 change: 0 additions & 1 deletion systemtests/tests/chflags/testrunner
Expand Up @@ -62,7 +62,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs

Expand Down
2 changes: 0 additions & 2 deletions systemtests/tests/client-initiated/testrunner
Expand Up @@ -90,8 +90,6 @@ run_bconsole "$tmp/bconcmds"

check_for_zombie_jobs storage=File

stop_bareos

check_two_logs
check_restore_diff "${BackupDirectory}"
end_test
1 change: 0 additions & 1 deletion systemtests/tests/copy-archive-job/testrunner
Expand Up @@ -58,7 +58,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_sd_files_written $tmp/log2.out
check_sd_files_written $tmp/log3.out
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/dbcopy-mysql-postgresql/testrunner
Expand Up @@ -80,7 +80,6 @@ END_OF_DATA

run_bareos
check_for_zombie_jobs storage=File client=bareos-fd
stop_bareos

check_two_logs
check_restore_diff "${BackupDirectory}"
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/droplet-s3/testrunner
Expand Up @@ -55,7 +55,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
check_restore_diff "${BackupDirectory}"
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/encrypt-signature/testrunner
Expand Up @@ -52,7 +52,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
check_restore_diff "${BackupDirectory}"
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/filesets/testrunner
Expand Up @@ -60,7 +60,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

for i in $TESTS; do
if ! grep -q $tmp/$i/data2.txt $tmp/estimate-$i.out; then
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/gfapi-fd/testrunner
Expand Up @@ -136,7 +136,6 @@ quit
END_OF_DATA_RESTORE
run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
ln -s "${tmp}" "${tmp}/bareos-restores"
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/glusterfs-backend/testrunner
Expand Up @@ -51,7 +51,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
check_restore_diff ${BackupDirectory}
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/list-backups/testrunner
Expand Up @@ -51,7 +51,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

echo "Checking list backups for jobtype=backup"
grep -F '1 | backup-bareos-fd | bareos-fd' "$tmp/list-backups.out"
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/multiplied-device/testrunner
Expand Up @@ -85,7 +85,6 @@ quit
END_OF_DATA

run_bconsole
stop_bareos

# rename files to be able to run the test again later
mv ./etc/bareos/bareos-dir.d/storage/fakestorage1.conf_backup ./etc/bareos/bareos-dir.d/storage/fakestorage1.conf
Expand Down
2 changes: 0 additions & 2 deletions systemtests/tests/ndmp/testrunner
Expand Up @@ -165,6 +165,4 @@ cleanup_isilon

check_for_zombie_jobs storage=isilonfile client=bareos-fd

stop_bareos

end_test
1 change: 0 additions & 1 deletion systemtests/tests/notls/testrunner
Expand Up @@ -61,7 +61,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
check_restore_diff ${BackupDirectory}
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/passive/testrunner
Expand Up @@ -51,7 +51,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
check_restore_diff ${BackupDirectory}
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/pruning/testrunner
Expand Up @@ -157,7 +157,6 @@ END_OF_DATA
run_bconsole

check_for_zombie_jobs storage=File
stop_bareos

check_two_logs

Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/py2plug-dir/testrunner
Expand Up @@ -53,7 +53,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

for i in bDirEventJobStart bDirEventJobInit bDirEventJobRun bDirEventJobEnd; do
if ! grep -q "$i" ${tmp}/test-plugin1.log; then
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/py2plug-fd-libcloud/testrunner
Expand Up @@ -99,7 +99,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
list=( $(find "${BackupDirectory}" -type f) )
Expand Down
Expand Up @@ -26,9 +26,6 @@ JobName=backup-bareos-fd
"${rscripts}"/cleanup
"${rscripts}"/setup




# Fill ${BackupDirectory} with data.
setup_data

Expand Down Expand Up @@ -62,7 +59,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
list=( $(find "${BackupDirectory}" -type f) )
Expand Down
5 changes: 0 additions & 5 deletions systemtests/tests/py2plug-fd-local-fileset/testrunner
Expand Up @@ -26,9 +26,6 @@ JobName=backup-bareos-fd
"${rscripts}"/cleanup
"${rscripts}"/setup




# Fill ${BackupDirectory} with data.
setup_data

Expand Down Expand Up @@ -65,7 +62,6 @@ fi
check_for_zombie_jobs storage=File
stop_bareos


cat <<END_OF_DATA >$tmp/bconcmds
@#
@# now do a restore
Expand All @@ -79,7 +75,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
check_restore_diff ${BackupDirectory}
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/py2plug-fd-mariabackup/testrunner
Expand Up @@ -116,7 +116,6 @@ if ! echo "SELECT * from test " | $MYSQL_CLIENT "${mariabackup_test_db}" | grep
fi

check_for_zombie_jobs storage=File
stop_bareos

mysql_server_stop

Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/py2plug-fd-ovirt/testrunner.in
Expand Up @@ -50,7 +50,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs

Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/py2plug-fd-percona-xtrabackup/testrunner
Expand Up @@ -115,7 +115,6 @@ fi


check_for_zombie_jobs storage=File
stop_bareos

mysql_server_stop

Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/py2plug-fd-vmware/testrunner
Expand Up @@ -65,7 +65,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs

Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/py2plug-sd/testrunner
Expand Up @@ -52,7 +52,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

events=(bsdEventJobStart
bsdEventDeviceReserve
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/spool/testrunner
Expand Up @@ -52,7 +52,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
check_restore_diff ${BackupDirectory}
Expand Down
@@ -1,6 +1,6 @@
# BAREOS® - Backup Archiving REcovery Open Sourced
#
# Copyright (C) 2021-2021 Bareos GmbH & Co. KG
# Copyright (C) 2021-2022 Bareos GmbH & Co. KG
#
# This program is Free Software; you can redistribute it and/or
# modify it under the terms of version three of the GNU Affero General Public
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/tls-certificate-encryption/testrunner
Expand Up @@ -48,7 +48,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
check_restore_diff ${BackupDirectory}
Expand Down
3 changes: 0 additions & 3 deletions systemtests/tests/truncate-command/testrunner
Expand Up @@ -70,9 +70,6 @@ run_bconsole ${tmp}/bconcmds2
# verify that all are terminated
check_for_zombie_jobs storage=File1 client=${Client}

# stop bareos
stop_bareos

# check tmp/log1.out and tmp/log2.out for errors
check_two_logs

Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/virtualfull-bscan/testrunner
Expand Up @@ -128,7 +128,6 @@ END_OF_DATA
run_bconsole "$tmp/bconcmds2"

check_for_zombie_jobs storage=File
stop_bareos

check_two_logs
check_restore_diff "${BackupDirectory}"
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/virtualfull/testrunner
Expand Up @@ -119,7 +119,6 @@ END_OF_DATA
run_bconsole "$tmp/bconcmds3"
check_for_zombie_jobs storage=File
check_two_logs
stop_bareos

if ! grep -q "Consolidating JobIds 1,2 containing 74 files" "$tmp/log1.out"; then
echo "Consolidation message was not emitted" >&2
Expand Down
1 change: 0 additions & 1 deletion systemtests/tests/xattr/testrunner
Expand Up @@ -62,7 +62,6 @@ END_OF_DATA

run_bareos "$@"
check_for_zombie_jobs storage=File
stop_bareos

check_two_logs

Expand Down

0 comments on commit 2288374

Please sign in to comment.