selftest: Add common fork_and_exec() function
authorTim Beale <timbeale@catalyst.net.nz>
Thu, 23 May 2019 04:35:07 +0000 (16:35 +1200)
committerAndrew Bartlett <abartlet@samba.org>
Fri, 24 May 2019 03:19:17 +0000 (03:19 +0000)
commitb976502d496cca0e8e04a2e5f2c72383efb296a7
treeed89628098c6a785a76bae2eb65bdd8791a3282c
parent746e137777e559afb7851a359d56580c58231ddd
selftest: Add common fork_and_exec() function

Now the code has been refactored, we can move it into a common function.
This reduces code duplication and means we have a common place where we
start samba daemons from.

Note that some daemons behave slightly different, but the $daemon_ctx
allows us to customize their behaviour a bit.

Signed-off-by: Tim Beale <timbeale@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
selftest/target/Samba.pm
selftest/target/Samba3.pm
selftest/target/Samba4.pm