summaryrefslogtreecommitdiff
path: root/ctdb/tests/tool/ctdb.stop.003.sh
diff options
context:
space:
mode:
authorMartin Schwenke <martin@meltin.net>2016-07-20 21:37:50 +1000
committerAmitay Isaacs <amitay@samba.org>2016-07-25 21:29:47 +0200
commitbd17dae3a0a66e2f6782dab667e5b0800ecdcab4 (patch)
tree91a6db37b61ac38bb8b728834db5050f34f33061 /ctdb/tests/tool/ctdb.stop.003.sh
parent8deb57b855dff6b8f7df543f9dff41782f27f518 (diff)
downloadsamba-bd17dae3a0a66e2f6782dab667e5b0800ecdcab4.tar.gz
ctdb-tests: Add "ctdb stop/continue" tool tests
Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
Diffstat (limited to 'ctdb/tests/tool/ctdb.stop.003.sh')
-rwxr-xr-xctdb/tests/tool/ctdb.stop.003.sh24
1 files changed, 24 insertions, 0 deletions
diff --git a/ctdb/tests/tool/ctdb.stop.003.sh b/ctdb/tests/tool/ctdb.stop.003.sh
new file mode 100755
index 00000000000..b6d1234ab8c
--- /dev/null
+++ b/ctdb/tests/tool/ctdb.stop.003.sh
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+. "${TEST_SCRIPTS_DIR}/unit.sh"
+
+define_test "node is already stopped"
+
+setup_ctdbd <<EOF
+NODEMAP
+0 192.168.20.41 0x0 CURRENT RECMASTER
+1 192.168.20.42 0x0
+2 192.168.20.43 0x20
+EOF
+
+ok "Node 2 is already stopped"
+simple_test -n 2
+
+required_result 32 <<EOF
+Number of nodes:3
+pnn:0 192.168.20.41 OK (THIS NODE)
+pnn:1 192.168.20.42 OK
+pnn:2 192.168.20.43 STOPPED|INACTIVE
+EOF
+EOF
+simple_test_other nodestatus all