We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e06b845 commit b3daff2Copy full SHA for b3daff2
1 file changed
src/test/java/org/apache/commons/csv/issues/JiraCsv247Test.java
@@ -67,14 +67,16 @@ public void testHeadersMissingThrowsWhenNotAllowingMissingColumnNames() {
67
assertFalse(format.getAllowMissingColumnNames(), "By default we should not allow missing column names");
68
69
assertThrows(IllegalArgumentException.class, () -> {
70
- try (final Reader in = new StringReader("a,,c,d,e\n1,2,3,4,5\nv,w,x,y,z")) {
71
- format.parse(in);
+ try (final Reader reader = new StringReader("a,,c,d,e\n1,2,3,4,5\nv,w,x,y,z");
+ CSVParser parser = format.parse(reader);) {
72
+ // should fail
73
}
74
}, "1 missing column header is not allowed");
75
76
- try (final Reader in = new StringReader("a,,c,d,\n1,2,3,4,5\nv,w,x,y,z")) {
77
+ try (final Reader reader = new StringReader("a,,c,d,\n1,2,3,4,5\nv,w,x,y,z");
78
79
80
81
}, "2+ missing column headers is not allowed!");
82
0 commit comments