Skip to content
Snippets Groups Projects
Commit dba516ee authored by Per Cederqvist's avatar Per Cederqvist
Browse files

Match all output. Somehow this test didn't fail even though there

were unmatched output from lyskomd.  Strange.
parent 7e3684d3
No related branches found
No related tags found
No related merge requests found
...@@ -181,25 +181,16 @@ simple_expect "MSG: garb ready. 0 texts deleted." ...@@ -181,25 +181,16 @@ simple_expect "MSG: garb ready. 0 texts deleted."
system "kill -HUP $new_pid" system "kill -HUP $new_pid"
set bypass 0 set bypass 0
set test "non-stale lyskomd sent final line" set test "non-stale lyskomd sent final line"
expect { simple_expect "Signal HUP received. Shutting down server."
-re "^\[0-9 :\]* $new_pid Press enter to terminate lyskomd$nl" { simple_expect "../lyskomd terminated normally."
pass "$test" simple_expect "Press enter to terminate lyskomd"
}
eof {
fail "$test (unexpected EOF)"
wait
set bypass 1
}
}
unset test
if {$bypass == 0} {
send "\n" send "\n"
set test "non-stale lyskomd died" set test "non-stale lyskomd died"
expect { expect {
eof { pass "$test"; wait } eof { pass "$test"; wait }
} }
unset test unset test
}
# Start a new lyskomd while a lock file for a remote system exists. # Start a new lyskomd while a lock file for a remote system exists.
system "ln -s inet.lysator.liu.se:4711 db/lyskomd-lock" system "ln -s inet.lysator.liu.se:4711 db/lyskomd-lock"
...@@ -215,6 +206,12 @@ expect { ...@@ -215,6 +206,12 @@ expect {
pass "$test" pass "$test"
} }
} }
set test "lock complaint"
expect {
-re "^\[0-9 :\]* Cannot obtain database lock. Exiting.$nl" {
pass "$test"
}
}
set test "local lyskomd sent final line" set test "local lyskomd sent final line"
expect { expect {
-re "^\[0-9 :\]* Press enter to terminate lyskomd$nl" { -re "^\[0-9 :\]* Press enter to terminate lyskomd$nl" {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment