Skip to content

Commit 9b4f58e

Browse files
authored
Fix HelpTests to work also on windows (#1295)
Signed-off-by: czpilar <[email protected]>
1 parent 90ea574 commit 9b4f58e

File tree

1 file changed

+3
-3
lines changed
  • spring-shell-core/src/test/java/org/springframework/shell/core/command

1 file changed

+3
-3
lines changed

spring-shell-core/src/test/java/org/springframework/shell/core/command/HelpTests.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ void testDefaultHelpMessage() throws Exception {
4949
quit, exit: Exit the shell
5050
5151
""";
52-
Assertions.assertEquals(expectedOutput, actualOutput);
52+
Assertions.assertEquals(expectedOutput.replaceAll("\\R", "\n"), actualOutput.replaceAll("\\R", "\n"));
5353
}
5454

5555
@Test
@@ -118,7 +118,7 @@ void testHelpMessageForCommand() throws Exception {
118118
119119
120120
""";
121-
Assertions.assertEquals(expectedOutput, actualOutput);
121+
Assertions.assertEquals(expectedOutput.replaceAll("\\R", "\n"), actualOutput.replaceAll("\\R", "\n"));
122122
}
123123

124124
@Test
@@ -190,7 +190,7 @@ void testHelpMessageForCommandAlias() throws Exception {
190190
hello, hey
191191
192192
""";
193-
Assertions.assertEquals(expectedOutput, actualOutput);
193+
Assertions.assertEquals(expectedOutput.replaceAll("\\R", "\n"), actualOutput.replaceAll("\\R", "\n"));
194194
}
195195

196196
}

0 commit comments

Comments
 (0)