summaryrefslogtreecommitdiff
path: root/ctdb/tests
diff options
context:
space:
mode:
authorMartin Schwenke <martin@meltin.net>2019-08-12 22:10:41 +1000
committerAmitay Isaacs <amitay@samba.org>2019-08-14 09:11:35 +0000
commit061656d383772b27607b8feb4a4ea9c988ce17d8 (patch)
tree9bc7c7c45b1d958c0aa857caa517da197e237e85 /ctdb/tests
parentb1d36e94d2edbab89d7db5055b13689d94b128ad (diff)
downloadsamba-061656d383772b27607b8feb4a4ea9c988ce17d8.tar.gz
ctdb-tests: Simplify test_wrap script
Given other improvements, this is now needlessly complex. Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Diffstat (limited to 'ctdb/tests')
-rwxr-xr-xctdb/tests/scripts/test_wrap18
1 files changed, 4 insertions, 14 deletions
diff --git a/ctdb/tests/scripts/test_wrap b/ctdb/tests/scripts/test_wrap
index 3db3180ae98..d9a6d09e202 100755
--- a/ctdb/tests/scripts/test_wrap
+++ b/ctdb/tests/scripts/test_wrap
@@ -1,20 +1,10 @@
#!/bin/bash
-# Execute the given command. The intention is that it is a function
-# from "${TEST_SCRIPTS_DIR}/integration.bash".
+# Execute the given command. The intention is that it is either
+# * a function from "${TEST_SCRIPTS_DIR}/integration.bash"; or
+# * a test helper binary
-PATH="$(dirname $0):${PATH}"
-
-TEST_SCRIPTS_DIR=$(dirname $0)
-
-# We need the test binaries (i.e. tests/bin/) to be in $PATH. If they
-# aren't already in $PATH then we know that tests/bin/ sits alongside
-# tests/scripts/.
-f="fetch_ring"
-if [ ! $(which $f >/dev/null 2>&1) ] ; then
- d=$(dirname "$TEST_SCRIPTS_DIR")/bin
- [ -x "$d/$f" ] && PATH="$d:$PATH"
-fi
+TEST_SCRIPTS_DIR=$(dirname "$0")
. "${TEST_SCRIPTS_DIR}/integration.bash"