Unverified Commit 02ef355f authored by Oran Agra's avatar Oran Agra Committed by GitHub
Browse files

runtest --stop pause stops before terminating the redis server (#7513)

in the majority of the cases (on this rarely used feature) we want to
stop and be able to connect to the shard with redis-cli.
since these are two different processes interracting with the tty we
need to stop both, and we'll have to hit enter twice, but it's not that
bad considering it is rarely used.
parent 7f19a04f
...@@ -153,6 +153,12 @@ proc test {name code {okpattern undefined}} { ...@@ -153,6 +153,12 @@ proc test {name code {okpattern undefined}} {
incr ::num_failed incr ::num_failed
send_data_packet $::test_server_fd err [join $details "\n"] send_data_packet $::test_server_fd err [join $details "\n"]
if {$::stop_on_failure} {
puts "Test error (last server port:[srv port], log:[srv stdout]), press enter to teardown the test."
flush stdout
gets stdin
}
} else { } else {
# Re-raise, let handler up the stack take care of this. # Re-raise, let handler up the stack take care of this.
error $error $::errorInfo error $error $::errorInfo
......
...@@ -359,8 +359,8 @@ proc read_from_test_client fd { ...@@ -359,8 +359,8 @@ proc read_from_test_client fd {
puts $err puts $err
lappend ::failed_tests $err lappend ::failed_tests $err
set ::active_clients_task($fd) "(ERR) $data" set ::active_clients_task($fd) "(ERR) $data"
if {$::stop_on_failure} { if {$::stop_on_failure} {
puts -nonewline "(Test stopped, press enter to continue)" puts -nonewline "(Test stopped, press enter to resume the tests)"
flush stdout flush stdout
gets stdin gets stdin
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment