mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-15 13:02:19 +00:00
Fix test failing on Windows because of line feed assumption
The line separator length was assumed to be 1 byte wide, although it could be 2 on some platforms (aka Windows).
This commit is contained in:
1 parent
9e05e0dec9
commit
fceabf0f0f
1 file changed
+2
-1
@@ -189,7 +189,8 @@ public class RunTest {
|
||||
for (int i = 1; i < 10; i++) {
|
||||
assertEquals("dummy" + (10+i), logLines.get(i));
|
||||
}
|
||||
assertEquals("[...truncated 68 B...]", logLines.get(0));
|
||||
int truncatedCount = 10* ("dummyN".length() + System.getProperty("line.separator").length()) - 2;
|
||||
assertEquals("[...truncated "+truncatedCount+" B...]", logLines.get(0));
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in new issue
Block a user