Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions src/SignalR/server/StackExchangeRedis/test/Docker.cs
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ public int RunCommand(string commandAndArguments, string prefix, out string outp

public int RunCommand(string commandAndArguments, string prefix, ILogger logger, out string output)
{
return RunProcessAndWait(_path, commandAndArguments, prefix, logger, TimeSpan.FromSeconds(5), out output);
return RunProcessAndWait(_path, commandAndArguments, prefix, logger, TimeSpan.FromSeconds(30), out output);
}

private static void RunProcessAndThrowIfFailed(string fileName, string arguments, string prefix, ILogger logger, TimeSpan timeout)
Expand All @@ -155,10 +155,14 @@ private static int RunProcessAndWait(string fileName, string arguments, string p
{
process.Close();
logger.LogError("Closing process '{processName}' because it is running longer than the configured timeout.", fileName);
output = string.Join(Environment.NewLine, lines.ToArray());
return -1;
}
else
{
// Need to WaitForExit without a timeout to guarantee the output stream has written everything
process.WaitForExit();
}

// Need to WaitForExit without a timeout to guarantee the output stream has written everything
process.WaitForExit();

output = string.Join(Environment.NewLine, lines);

Expand Down