ctdb-tests: Depend on setup_ctdb_base() to install events.d/
authorMartin Schwenke <martin@meltin.net>
Fri, 16 Feb 2018 03:27:39 +0000 (14:27 +1100)
committerMartin Schwenke <martins@samba.org>
Fri, 9 Mar 2018 06:08:25 +0000 (07:08 +0100)
This directory is only used by simple tests when running against local
daemons.  Moving it to simple/etc-ctdb/events.d/ means that it is
automatically copied by setup_ctdb_base().

Signed-off-by: Martin Schwenke <martin@meltin.net>
Reviewed-by: Amitay Isaacs <amitay@gmail.com>
ctdb/tests/simple/etc-ctdb/events.d/00.test [moved from ctdb/tests/events.d/00.test with 100% similarity]
ctdb/tests/simple/scripts/local_daemons.bash
ctdb/wscript

index a0fae2a32d4b5bda95c21652e66ac720a11951df..07758fb74fba5edaf57367c354220b03e5b53ddf 100644 (file)
@@ -134,16 +134,6 @@ setup_public_addresses ()
 
 setup_ctdb ()
 {
-       # When running certain tests we add and remove eventscripts, so we
-       # need to be able to modify the events.d/ directory.  Therefore,
-       # we use a temporary events.d/ directory under $TEST_VAR_DIR.  We
-       # copy the actual test eventscript(s) in there from the original
-       # events.d/ directory that sits alongside $TEST_SCRIPT_DIR.
-       local top=$(dirname "$TEST_SCRIPTS_DIR")
-       local events_d="${top}/events.d"
-       mkdir -p "${TEST_VAR_DIR}/events.d"
-       cp -p "${events_d}/"* "${TEST_VAR_DIR}/events.d/"
-
        setup_nodes >"$CTDB_NODES" || return 1
 
        # If there are (strictly) greater than 2 nodes then we'll
@@ -188,7 +178,6 @@ setup_ctdb ()
 CTDB_RECOVERY_LOCK="${SIMPLE_TESTS_VAR_DIR}/rec.lock"
 CTDB_NODES="$CTDB_NODES"
 CTDB_NODE_ADDRESS="${node_ip}"
-CTDB_EVENT_SCRIPT_DIR="${TEST_VAR_DIR}/events.d"
 CTDB_LOGGING="file:${node_dir}/log.ctdb"
 CTDB_DEBUGLEVEL=INFO
 CTDB_DBDIR="${db_dir}"
index 065f610b8d9bfb78f77a5bcd2fd33e62a58e8bc0..74e37ead86dd3de8cafa6b25fbf017a6f1d46ea5 100644 (file)
@@ -880,7 +880,6 @@ def build(bld):
         'complex',
         'cunit',
         'eventd',
-        'events.d',
         'eventscripts',
         'onnode',
         'shellcheck',