1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-26 10:04:02 +03:00
Martin Schwenke 7cddc88d03 ctdb-tests: 01.reclock event script setup modularisation
Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
2018-03-28 02:57:18 +02:00

16 lines
311 B
Bash

cleanup_reclock ()
{
_pattern="${script_dir}/${script}"
while pgrep -f "$_pattern" >/dev/null ; do
echo "Waiting for backgrounded ${script} to exit..."
(FAKE_SLEEP_REALLY=yes sleep 1)
done
}
setup ()
{
export CTDB_RECOVERY_LOCK="${EVENTSCRIPTS_TESTS_VAR_DIR}/rec.lock"
test_cleanup cleanup_reclock
}