From cc5a044a8c140e32868bb0f312f3780161515f0b Mon Sep 17 00:00:00 2001 From: "Guillaume J. Charmes" Date: Fri, 19 Apr 2013 17:51:41 -0700 Subject: [PATCH] update TestRunDisconnectTty to reflect the correct behavior of CmdRun --- commands_test.go | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/commands_test.go b/commands_test.go index 1be4a2abe0..9615e877e6 100644 --- a/commands_test.go +++ b/commands_test.go @@ -239,11 +239,8 @@ func TestRunDisconnectTty(t *testing.T) { t.Fatal(err) } - // as the pipes are close, we expect the process to die, - // therefore CmdRun to unblock. Wait for CmdRun - setTimeout(t, "Waiting for CmdRun timed out", 2*time.Second, func() { - <-c1 - }) + // In tty mode, we expect the process to stay alive even after client's stdin closes. + // Do not wait for run to finish // Client disconnect after run -i should keep stdin out in TTY mode container := runtime.List()[0]