mirror of
https://github.com/samba-team/samba.git
synced 2025-01-25 06:04:04 +03:00
480c586c7d
Instead of using an intermediate environment variable for nodes files, just create "node" or "nodes.<pnn>" in CTDB_BASE. This makes the nodes file loading in fake_ctdb slightly repetitive but simplifies the test scripts a lot. It also remove several instance of the CTDB_NODES variable from the code base, so it is no longer found by "git grep". Use an empty nodes file to indicate that fake_ctdbd should fail to read it. Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
21 lines
270 B
Bash
Executable File
21 lines
270 B
Bash
Executable File
#!/bin/sh
|
|
|
|
. "${TEST_SCRIPTS_DIR}/unit.sh"
|
|
|
|
define_test "missing nodes file"
|
|
|
|
setup_nodes <<EOF
|
|
192.168.20.41
|
|
192.168.20.42
|
|
192.168.20.43
|
|
EOF
|
|
|
|
f="${CTDB_BASE}/nodes"
|
|
rm -f "$f"
|
|
|
|
required_result 1 <<EOF
|
|
${TEST_DATE_STAMP}Failed to read nodes file "${f}"
|
|
EOF
|
|
|
|
simple_test
|