Skip to content

Commit a5e21ef

Browse files
committed
Fix bug in test.
1 parent d4e0999 commit a5e21ef

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/test/java/org/apache/commons/csv/issues/JiraCsv149Test.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,17 @@
3030
@Disabled
3131
public class JiraCsv149Test {
3232

33+
private static final String CR_LF = "\r\n";
34+
3335
@Test
3436
public void testJiraCsv149EndWithEOL() throws IOException {
3537
testJiraCsv149EndWithEolAtEof(true);
3638
}
3739

3840
private void testJiraCsv149EndWithEolAtEof(boolean eolAtEof) throws IOException {
39-
String source = "A,B,C,D\r\n" + "a1,b1,c1,d1\r\n" + "a2,b2,c2,d2";
41+
String source = "A,B,C,D" + CR_LF + "a1,b1,c1,d1" + CR_LF + "a2,b2,c2,d2";
4042
if (eolAtEof) {
41-
source += "\\r\\n";
43+
source += CR_LF;
4244
}
4345
final StringReader records = new StringReader(source);
4446
final CSVFormat format = CSVFormat.RFC4180.withFirstRecordAsHeader().withQuote('"');

0 commit comments

Comments
 (0)