We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0687c9a commit 0d4abbeCopy full SHA for 0d4abbe
core/src/main/java/cucumber/runtime/formatter/PrettyFormatter.java
@@ -153,11 +153,10 @@ private void handleTestStepFinished(TestStepFinished event) {
153
private void handleWrite(WriteEvent event) {
154
out.println();
155
try(BufferedReader lines = new BufferedReader(new StringReader(event.text))) {
156
- String line = lines.readLine();
157
- while(line != null) {
158
- out.println(STEP_SCENARIO_INDENT + line);
159
- line = lines.readLine();
160
- }
+ String line;
+ while ((line = lines.readLine()) != null) {
+ out.println(STEP_SCENARIO_INDENT + line);
+ }
161
} catch (IOException e) {
162
throw new CucumberException(e);
163
}
0 commit comments