summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 09ea0a4)
raw | patch | inline | side by side (parent: 09ea0a4)
author | Sebastian Harl <sh@tokkee.org> | |
Mon, 28 Apr 2014 07:52:35 +0000 (09:52 +0200) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Mon, 28 Apr 2014 07:52:35 +0000 (09:52 +0200) |
t/integration/simple_config.sh | patch | blob | history | |
t/integration/simple_query.sh | patch | blob | history | |
t/integration/test_lib.sh | patch | blob | history |
index 3484351420e48dce24d491717b467b0bc679b57e..677f53c05d8c2038bab85435dd8947de85d7efcb 100755 (executable)
source "$( dirname "$0" )/test_lib.sh"
-cat <<EOF > "$TESTDIR/sysdbd.conf"
+cat <<EOF > "$SYSDBD_CONF"
Listen "invalid://address"
EOF
-if "$TOP_SRCDIR/src/sysdbd" -D -C "$TESTDIR/sysdbd.conf"; then
+if "$SYSDBD" -D -C "$SYSDBD_CONF"; then
echo 'SysDBd accepted invalid listen address; expected: failure' >&2
exit 1
fi
-cat <<EOF > "$TESTDIR/sysdbd.conf"
+cat <<EOF > "$SYSDBD_CONF"
Listen "$SOCKET_FILE"
EOF
-"$TOP_SRCDIR/src/sysdbd" -D -C "$TESTDIR/sysdbd.conf" &
+"$SYSDBD" -D -C "$SYSDBD_CONF" &
sysdbd_pid=$!
wait_for_sysdbd
index 37c57a1b4221387404ce2ddb9002cfc1a70e8adf..d091e2b4b8d375d4bbf00c738de0c51792ac9e68 100755 (executable)
source "$( dirname "$0" )/test_lib.sh"
-cat <<EOF > "$TESTDIR/sysdbd.conf"
+cat <<EOF > "$SYSDBD_CONF"
Listen "$SOCKET_FILE"
PluginDir "$PLUGIN_DIR"
Interval 2
</Backend>
EOF
-"$TOP_SRCDIR/src/sysdbd" -D -C "$TESTDIR/sysdbd.conf" &
+"$SYSDBD" -D -C "$SYSDBD_CONF" &
sysdbd_pid=$!
wait_for_sysdbd
sleep 3
-"$TOP_SRCDIR/src/sysdb" -H "$SOCKET_FILE" -c LIST \
+"$SYSDB" -H "$SOCKET_FILE" -c LIST \
| grep -F '"host1.example.com"' \
| grep -F "host2.example.com" \
| grep -F "localhost" \
index 85bffb9401cd2844605f83e757163459846721fe..b91cb0c37edafbe939d5803bc6410cad656e8869 100644 (file)
mkdir "$TESTDIR/backend"
cp "$TOP_SRCDIR/t/integration/.libs/mock_plugin.so" "$TESTDIR/backend"
+SYSDBD_CONF="$TESTDIR/sysdbd.conf"
+
SOCKET_FILE="$TESTDIR/sock"
PLUGIN_DIR="$TESTDIR"
+SYSDBD="$TOP_SRCDIR/src/sysdbd"
+SYSDB="$TOP_SRCDIR/src/sysdb"
+
function wait_for_sysdbd() {
local i
for (( i=0; i<10; i++ )); do