Fix crash on some corruption when importing CSV

Commons-CSV would throw a RuntimeException in some cases of
bad CSV input. This was later changed to throwing an
IllegalStateException. Updating to v1.5 to pick-up the change.
This commit is contained in:
Branden Archer committed 2018-01-16 22:04:36 -05:00
1 parent a3a70d459b
commit 43072e283f
3 files changed
+7 -3

No files matched your search

@@ -198,7 +198,11 @@ public class ImportExportTest
clearDatabase();
String corruptEntry = "ThisStringIsLikelyNotPartOfAnyFormat";
// commons-csv would throw a RuntimeException if an entry was quotes but had
// content after. For example:
// abc,def,""abc,abc
// ^ after the quote there should only be a , \n or EOF
String corruptEntry = "ThisStringIsLikelyNotPartOfAnyFormat,\"\"a";
ByteArrayInputStream inData = new ByteArrayInputStream((outData.toString() + corruptEntry).getBytes());
InputStreamReader inStream = new InputStreamReader(inData);