Useful for being able to ensure that tests are doing what is expected.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12254
Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
wait_until_ready
-# If this fails to find processes then the tests fails, so look at
-# full command-line so this will work with valgrind. Note that the
-# output could be generated with pgrep's -a option but it doesn't
-# exist in older versions.
-ps -p $(pgrep -f '\<ctdbd\>' | xargs | sed -e 's| |,|g') -o args ww
+ps_ctdbd
-echo
echo "Good, that seems to work!"
daemons_stop
daemons_start
}
+
+ps_ctdbd ()
+{
+ # If this fails to find processes then the tests fails, so
+ # look at full command-line so this will work with valgrind.
+ # Note that the output could be generated with pgrep's -a
+ # option but it doesn't exist in older versions.
+ ps -p $(pgrep -f '\<ctdbd\>' | xargs | sed -e 's| |,|g') -o args ww
+ echo
+}