From 4f5791ebd03eaec1c7da0865a383175b05102712 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 5 May 2024 19:47:29 +0200 Subject: Adding upstream version 2:4.17.12+dfsg. Signed-off-by: Daniel Baumann --- ctdb/tests/UNIT/tool/README | 17 ++++ ctdb/tests/UNIT/tool/ctdb.attach.001.sh | 35 +++++++ ctdb/tests/UNIT/tool/ctdb.attach.002.sh | 35 +++++++ ctdb/tests/UNIT/tool/ctdb.attach.003.sh | 35 +++++++ ctdb/tests/UNIT/tool/ctdb.ban.001.sh | 35 +++++++ ctdb/tests/UNIT/tool/ctdb.ban.002.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.ban.003.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.catdb.001.sh | 80 ++++++++++++++++ ctdb/tests/UNIT/tool/ctdb.catdb.002.sh | 86 +++++++++++++++++ ctdb/tests/UNIT/tool/ctdb.cattdb.001.sh | 80 ++++++++++++++++ ctdb/tests/UNIT/tool/ctdb.cattdb.002.sh | 86 +++++++++++++++++ ctdb/tests/UNIT/tool/ctdb.continue.001.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.continue.002.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.continue.003.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.deletekey.001.sh | 34 +++++++ ctdb/tests/UNIT/tool/ctdb.disable.001.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.disable.002.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.disable.003.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.disable.004.sh | 15 +++ ctdb/tests/UNIT/tool/ctdb.enable.001.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.enable.002.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.enable.003.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.getcapabilities.001.sh | 19 ++++ ctdb/tests/UNIT/tool/ctdb.getcapabilities.002.sh | 19 ++++ ctdb/tests/UNIT/tool/ctdb.getcapabilities.003.sh | 28 ++++++ ctdb/tests/UNIT/tool/ctdb.getcapabilities.004.sh | 39 ++++++++ ctdb/tests/UNIT/tool/ctdb.getdbmap.001.sh | 34 +++++++ ctdb/tests/UNIT/tool/ctdb.getdbseqnum.001.sh | 41 +++++++++ ctdb/tests/UNIT/tool/ctdb.getdbseqnum.002.sh | 36 ++++++++ ctdb/tests/UNIT/tool/ctdb.getdbstatus.001.sh | 108 ++++++++++++++++++++++ ctdb/tests/UNIT/tool/ctdb.getdbstatus.002.sh | 108 ++++++++++++++++++++++ ctdb/tests/UNIT/tool/ctdb.getpid.001.sh | 17 ++++ ctdb/tests/UNIT/tool/ctdb.getpid.010.sh | 25 +++++ ctdb/tests/UNIT/tool/ctdb.getreclock.001.sh | 16 ++++ ctdb/tests/UNIT/tool/ctdb.getreclock.002.sh | 21 +++++ ctdb/tests/UNIT/tool/ctdb.getvar.001.sh | 35 +++++++ ctdb/tests/UNIT/tool/ctdb.getvar.002.sh | 17 ++++ ctdb/tests/UNIT/tool/ctdb.ifaces.001.sh | 24 +++++ ctdb/tests/UNIT/tool/ctdb.ip.001.sh | 17 ++++ ctdb/tests/UNIT/tool/ctdb.ip.002.sh | 17 ++++ ctdb/tests/UNIT/tool/ctdb.ip.003.sh | 30 ++++++ ctdb/tests/UNIT/tool/ctdb.ip.004.sh | 29 ++++++ ctdb/tests/UNIT/tool/ctdb.ip.005.sh | 30 ++++++ ctdb/tests/UNIT/tool/ctdb.ip.006.sh | 30 ++++++ ctdb/tests/UNIT/tool/ctdb.ip.007.sh | 36 ++++++++ ctdb/tests/UNIT/tool/ctdb.ipinfo.001.sh | 18 ++++ ctdb/tests/UNIT/tool/ctdb.ipinfo.002.sh | 32 +++++++ ctdb/tests/UNIT/tool/ctdb.ipinfo.003.sh | 35 +++++++ ctdb/tests/UNIT/tool/ctdb.leader.001.sh | 16 ++++ ctdb/tests/UNIT/tool/ctdb.leader.002.sh | 16 ++++ ctdb/tests/UNIT/tool/ctdb.listnodes.001.sh | 20 ++++ ctdb/tests/UNIT/tool/ctdb.listnodes.002.sh | 19 ++++ ctdb/tests/UNIT/tool/ctdb.listvars.001.sh | 66 +++++++++++++ ctdb/tests/UNIT/tool/ctdb.lvs.001.sh | 36 ++++++++ ctdb/tests/UNIT/tool/ctdb.lvs.002.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.lvs.003.sh | 43 +++++++++ ctdb/tests/UNIT/tool/ctdb.lvs.004.sh | 45 +++++++++ ctdb/tests/UNIT/tool/ctdb.lvs.005.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.lvs.006.sh | 44 +++++++++ ctdb/tests/UNIT/tool/ctdb.lvs.007.sh | 42 +++++++++ ctdb/tests/UNIT/tool/ctdb.lvs.008.sh | 66 +++++++++++++ ctdb/tests/UNIT/tool/ctdb.lvs.010.sh | 25 +++++ ctdb/tests/UNIT/tool/ctdb.natgw.001.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.natgw.002.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.natgw.003.sh | 43 +++++++++ ctdb/tests/UNIT/tool/ctdb.natgw.004.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.natgw.005.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.natgw.006.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.natgw.007.sh | 45 +++++++++ ctdb/tests/UNIT/tool/ctdb.natgw.008.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.natgw.010.sh | 25 +++++ ctdb/tests/UNIT/tool/ctdb.nodestatus.001.sh | 33 +++++++ ctdb/tests/UNIT/tool/ctdb.nodestatus.002.sh | 33 +++++++ ctdb/tests/UNIT/tool/ctdb.nodestatus.003.sh | 33 +++++++ ctdb/tests/UNIT/tool/ctdb.nodestatus.004.sh | 28 ++++++ ctdb/tests/UNIT/tool/ctdb.nodestatus.005.sh | 28 ++++++ ctdb/tests/UNIT/tool/ctdb.nodestatus.006.sh | 40 ++++++++ ctdb/tests/UNIT/tool/ctdb.nodestatus.007.sh | 36 ++++++++ ctdb/tests/UNIT/tool/ctdb.pdelete.001.sh | 27 ++++++ ctdb/tests/UNIT/tool/ctdb.ping.001.sh | 24 +++++ ctdb/tests/UNIT/tool/ctdb.pnn.001.sh | 15 +++ ctdb/tests/UNIT/tool/ctdb.process-exists.001.sh | 28 ++++++ ctdb/tests/UNIT/tool/ctdb.process-exists.002.sh | 30 ++++++ ctdb/tests/UNIT/tool/ctdb.process-exists.003.sh | 30 ++++++ ctdb/tests/UNIT/tool/ctdb.pstore.001.sh | 24 +++++ ctdb/tests/UNIT/tool/ctdb.ptrans.001.sh | 49 ++++++++++ ctdb/tests/UNIT/tool/ctdb.readkey.001.sh | 20 ++++ ctdb/tests/UNIT/tool/ctdb.recover.001.sh | 22 +++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.001.sh | 24 +++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.002.sh | 30 ++++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.003.sh | 29 ++++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.011.sh | 25 +++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.012.sh | 24 +++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.013.sh | 26 ++++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.014.sh | 24 +++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.015.sh | 26 ++++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.016.sh | 24 +++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.017.sh | 26 ++++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.018.sh | 29 ++++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.019.sh | 28 ++++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.020.sh | 28 ++++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.021.sh | 26 ++++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.023.sh | 24 +++++ ctdb/tests/UNIT/tool/ctdb.reloadnodes.024.sh | 24 +++++ ctdb/tests/UNIT/tool/ctdb.runstate.001.sh | 15 +++ ctdb/tests/UNIT/tool/ctdb.runstate.002.sh | 15 +++ ctdb/tests/UNIT/tool/ctdb.runstate.003.sh | 17 ++++ ctdb/tests/UNIT/tool/ctdb.runstate.004.sh | 15 +++ ctdb/tests/UNIT/tool/ctdb.runstate.005.sh | 15 +++ ctdb/tests/UNIT/tool/ctdb.setdbreadonly.001.sh | 53 +++++++++++ ctdb/tests/UNIT/tool/ctdb.setdbreadonly.002.sh | 37 ++++++++ ctdb/tests/UNIT/tool/ctdb.setdbreadonly.003.sh | 39 ++++++++ ctdb/tests/UNIT/tool/ctdb.setdbreadonly.004.sh | 37 ++++++++ ctdb/tests/UNIT/tool/ctdb.setdbreadonly.005.sh | 39 ++++++++ ctdb/tests/UNIT/tool/ctdb.setdbsticky.001.sh | 53 +++++++++++ ctdb/tests/UNIT/tool/ctdb.setdbsticky.002.sh | 37 ++++++++ ctdb/tests/UNIT/tool/ctdb.setdbsticky.003.sh | 39 ++++++++ ctdb/tests/UNIT/tool/ctdb.setdbsticky.004.sh | 37 ++++++++ ctdb/tests/UNIT/tool/ctdb.setdbsticky.005.sh | 39 ++++++++ ctdb/tests/UNIT/tool/ctdb.setdebug.001.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.setdebug.002.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.setdebug.003.sh | 32 +++++++ ctdb/tests/UNIT/tool/ctdb.setifacelink.001.sh | 76 +++++++++++++++ ctdb/tests/UNIT/tool/ctdb.setifacelink.002.sh | 22 +++++ ctdb/tests/UNIT/tool/ctdb.setvar.001.sh | 49 ++++++++++ ctdb/tests/UNIT/tool/ctdb.setvar.002.sh | 17 ++++ ctdb/tests/UNIT/tool/ctdb.status.001.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.status.002.sh | 46 ++++++++++ ctdb/tests/UNIT/tool/ctdb.status.003.sh | 49 ++++++++++ ctdb/tests/UNIT/tool/ctdb.stop.001.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.stop.002.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.stop.003.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.unban.001.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.unban.002.sh | 34 +++++++ ctdb/tests/UNIT/tool/ctdb.unban.003.sh | 23 +++++ ctdb/tests/UNIT/tool/ctdb.uptime.001.sh | 36 ++++++++ ctdb/tests/UNIT/tool/ctdb.writekey.001.sh | 31 +++++++ ctdb/tests/UNIT/tool/scripts/local.sh | 112 +++++++++++++++++++++++ 138 files changed, 4686 insertions(+) create mode 100644 ctdb/tests/UNIT/tool/README create mode 100755 ctdb/tests/UNIT/tool/ctdb.attach.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.attach.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.attach.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ban.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ban.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ban.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.catdb.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.catdb.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.cattdb.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.cattdb.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.continue.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.continue.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.continue.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.deletekey.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.disable.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.disable.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.disable.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.disable.004.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.enable.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.enable.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.enable.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getcapabilities.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getcapabilities.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getcapabilities.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getcapabilities.004.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getdbmap.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getdbseqnum.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getdbseqnum.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getdbstatus.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getdbstatus.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getpid.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getpid.010.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getreclock.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getreclock.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getvar.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.getvar.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ifaces.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ip.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ip.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ip.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ip.004.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ip.005.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ip.006.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ip.007.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ipinfo.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ipinfo.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ipinfo.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.leader.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.leader.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.listnodes.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.listnodes.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.listvars.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.lvs.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.lvs.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.lvs.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.lvs.004.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.lvs.005.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.lvs.006.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.lvs.007.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.lvs.008.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.lvs.010.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.natgw.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.natgw.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.natgw.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.natgw.004.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.natgw.005.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.natgw.006.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.natgw.007.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.natgw.008.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.natgw.010.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.nodestatus.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.nodestatus.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.nodestatus.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.nodestatus.004.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.nodestatus.005.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.nodestatus.006.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.nodestatus.007.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.pdelete.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ping.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.pnn.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.process-exists.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.process-exists.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.process-exists.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.pstore.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.ptrans.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.readkey.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.recover.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.011.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.012.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.013.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.014.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.015.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.016.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.017.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.018.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.019.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.020.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.021.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.023.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.reloadnodes.024.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.runstate.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.runstate.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.runstate.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.runstate.004.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.runstate.005.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbreadonly.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbreadonly.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbreadonly.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbreadonly.004.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbreadonly.005.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbsticky.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbsticky.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbsticky.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbsticky.004.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdbsticky.005.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdebug.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdebug.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setdebug.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setifacelink.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setifacelink.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setvar.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.setvar.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.status.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.status.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.status.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.stop.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.stop.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.stop.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.unban.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.unban.002.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.unban.003.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.uptime.001.sh create mode 100755 ctdb/tests/UNIT/tool/ctdb.writekey.001.sh create mode 100644 ctdb/tests/UNIT/tool/scripts/local.sh (limited to 'ctdb/tests/UNIT/tool') diff --git a/ctdb/tests/UNIT/tool/README b/ctdb/tests/UNIT/tool/README new file mode 100644 index 0000000..8160528 --- /dev/null +++ b/ctdb/tests/UNIT/tool/README @@ -0,0 +1,17 @@ +Unit tests for the ctdb tool (i.e. tools/ctdb). + +Test case filenames can take 2 forms: + +* func..NNN.sh + + Run in the ctdb tool code using the + ctdb_tool_functest test program. This test program uses test stubs + for CTDB client functions. + +* stubby..NNN.sh + + Run the ctdb_tool_stubby test program with as the 1st + argument - subsequent are passed to simple_test(). ctdb_tool_stubby + is linked against the test stubs for CTDB client functions. + +To add tests here you may need to add appropriate test stubs. diff --git a/ctdb/tests/UNIT/tool/ctdb.attach.001.sh b/ctdb/tests/UNIT/tool/ctdb.attach.001.sh new file mode 100755 index 0000000..82c3332 --- /dev/null +++ b/ctdb/tests/UNIT/tool/ctdb.attach.001.sh @@ -0,0 +1,35 @@ +#!/bin/sh + +. "${TEST_SCRIPTS_DIR}/unit.sh" + +define_test "attach volatile database" + +setup_ctdbd < down + +ok_null +simple_test eth1 down + +ok < up + +ok_null +simple_test eth1 up + +ok < down +ok_null +simple_test eth1 down + +ok < down + +ok_null +simple_test eth2 down + +ok < up + +ok_null +simple_test eth1 up + +ok </dev/null || echo) + if [ -n "$pid" ] ; then + kill $pid || true + rm -f "$ctdbd_pidfile" + fi + rm -f "$ctdbd_socket" + rm -rf "$ctdbd_dbdir" +} + +setup_ctdbd () +{ + echo "Setting up fake ctdbd" + + mkdir -p "$ctdbd_dbdir" + $VALGRIND fake_ctdbd -d "$FAKE_CTDBD_DEBUGLEVEL" \ + -s "$ctdbd_socket" -p "$ctdbd_pidfile" \ + -D "$ctdbd_dbdir" + # Wait till fake_ctdbd is running + wait_until 10 test -S "$ctdbd_socket" || \ + die "fake_ctdbd failed to start" + + test_cleanup cleanup_ctdbd +} + +ctdbd_getpid () +{ + cat "$ctdbd_pidfile" +} + +setup_natgw () +{ + debug "Setting up NAT gateway" + + export CTDB_NATGW_HELPER="${CTDB_SCRIPTS_TOOLS_HELPER_DIR}/ctdb_natgw" + export CTDB_NATGW_NODES="${CTDB_BASE}/natgw_nodes" + + cat >"$CTDB_NATGW_NODES" +} + +setup_lvs () +{ + debug "Setting up LVS" + + export CTDB_LVS_HELPER="${CTDB_SCRIPTS_TOOLS_HELPER_DIR}/ctdb_lvs" + export CTDB_LVS_NODES="${CTDB_BASE}/lvs_nodes" + + cat >"$CTDB_LVS_NODES" +} + +setup_nodes () +{ + _pnn="$1" + + _f="${CTDB_BASE}/nodes${_pnn:+.}${_pnn}" + + cat >"$_f" +} + +simple_test_other () +{ + unit_test $CTDB -d $CTDB_DEBUGLEVEL "$@" +} + +simple_test () +{ + simple_test_other $test_args "$@" +} -- cgit v1.2.3