Skip to content

Commit d3c47cf

Browse files
committed
For --showResponse, use Write() if output redirected
1 parent 20bb284 commit d3c47cf

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

netmockery/TestRunner.cs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,14 @@ public void ShowResponse(int index)
6060
}
6161
else
6262
{
63-
WriteLine(response.Item1);
63+
if (IsOutputRedirected)
64+
{
65+
Write(response.Item1);
66+
}
67+
else
68+
{
69+
WriteLine(response.Item1);
70+
}
6471
}
6572
}
6673

0 commit comments

Comments
 (0)