mirror of
https://github.com/arduino/Arduino.git
synced 2025-03-13 10:29:35 +01:00
Fix CommandLineTest.testCommandLineVersion() on Windows
Fix CommandLineTest.testCommandLineVersion() failing on Windows due to Runtime.exec() returning `\r\n` line endings where the test expected `\n` line endings.
This commit is contained in:
parent
442007a926
commit
933bbb3a39
@ -139,10 +139,10 @@ public class CommandLineTest {
|
||||
pr.waitFor();
|
||||
|
||||
Assertions.assertThat(pr.exitValue())
|
||||
.as("Process will finish with exit code 0 in --version")
|
||||
.isEqualTo(0);
|
||||
.as("Process will finish with exit code 0 in --version")
|
||||
.isEqualTo(0);
|
||||
Assertions.assertThat(new String(IOUtils.toByteArray(pr.getInputStream())))
|
||||
.matches("Arduino: \\d+\\.\\d+\\.\\d+.*\n");
|
||||
.matches("Arduino: \\d+\\.\\d+\\.\\d+.*\r?\n");
|
||||
}
|
||||
|
||||
@Test
|
||||
@ -156,7 +156,7 @@ public class CommandLineTest {
|
||||
pr.waitFor();
|
||||
|
||||
Assertions.assertThat(pr.exitValue())
|
||||
.as("Multiple Action will be rejected")
|
||||
.isEqualTo(3);
|
||||
.as("Multiple Action will be rejected")
|
||||
.isEqualTo(3);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user