Commit 75a64bd9 authored by XenoAmess's avatar XenoAmess Committed by Andy Wilkinson

Fix unwrapping of captured PrintStream in test support's OutputCapture

See gh-22214
parent 43015800
...@@ -194,7 +194,7 @@ class OutputCapture implements CapturedOutput { ...@@ -194,7 +194,7 @@ class OutputCapture implements CapturedOutput {
private static PrintStream getSystemStream(PrintStream printStream) { private static PrintStream getSystemStream(PrintStream printStream) {
while (printStream instanceof PrintStreamCapture) { while (printStream instanceof PrintStreamCapture) {
return ((PrintStreamCapture) printStream).getParent(); printStream = ((PrintStreamCapture) printStream).getParent();
} }
return printStream; return printStream;
} }
......
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