From: Martin Schwenke Date: Mon, 8 Aug 2022 08:19:34 +0000 (+1000) Subject: ctdb-tests: Avoid shellcheck warnings X-Git-Tag: talloc-2.4.0~1334 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a0e0fde039e924d192294ad95da4344eff390c0c;p=thirdparty%2Fsamba.git ctdb-tests: Avoid shellcheck warnings Mostly SC2086: Double quote to prevent globbing and word splitting. Use ctdb_onnode() where it simplifies code. No behaviour changes intended. Signed-off-by: Martin Schwenke Reviewed-by: Amitay Isaacs Autobuild-User(master): Amitay Isaacs Autobuild-Date(master): Thu Aug 25 16:15:45 UTC 2022 on sn-devel-184 --- diff --git a/ctdb/tests/CLUSTER/complex/11_ctdb_delip_removes_ip.sh b/ctdb/tests/CLUSTER/complex/11_ctdb_delip_removes_ip.sh index 77e59f8c927..072780ac215 100755 --- a/ctdb/tests/CLUSTER/complex/11_ctdb_delip_removes_ip.sh +++ b/ctdb/tests/CLUSTER/complex/11_ctdb_delip_removes_ip.sh @@ -20,13 +20,15 @@ ctdb_test_init select_test_node_and_ips +# $test_node and $test_ip set by select_test_node_and_ips() +# shellcheck disable=SC2154 echo "Checking that node ${test_node} hosts ${test_ip}..." test_node_has_test_ip echo "Attempting to remove ${test_ip} from node ${test_node}." -try_command_on_node $test_node $CTDB delip $test_ip -try_command_on_node $test_node $CTDB ipreallocate -wait_until_ips_are_on_node '!' $test_node $test_ip +ctdb_onnode "$test_node" "delip ${test_ip}" +ctdb_onnode "$test_node" "ipreallocate" +wait_until_ips_are_on_node '!' "$test_node" "$test_ip" echo "Waiting for ${test_ip} to disappear from node ${test_node}..." wait_until 60/5 '!' test_node_has_test_ip