Skip to content

Commit 50a89da

Browse files
committed
Test empty files
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/csv/trunk@1305668 13f79535-47bb-0310-9956-ffa450edef68
1 parent c53d3f3 commit 50a89da

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/test/java/org/apache/commons/csv/CSVParserTest.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,12 @@ public void testEmptyLineBehaviourCSV() throws Exception {
217217
}
218218
}
219219

220+
@Test
221+
public void testEmptyFile() throws Exception {
222+
CSVParser parser = new CSVParser("", CSVFormat.DEFAULT);
223+
assertNull(parser.getRecord());
224+
}
225+
220226
@Test
221227
@Ignore
222228
public void testBackslashEscapingOld() throws IOException {

0 commit comments

Comments
 (0)