public class StatefulBeanToCsvWithCSVWriterTest extends Object
StatefulBeanToCsv.| Constructor and Description |
|---|
StatefulBeanToCsvWithCSVWriterTest() |
| Modifier and Type | Method and Description |
|---|---|
void |
bindCustomConverterToWrongDataType()
Tests binding a custom converter to the wrong data type.
|
void |
createWriters() |
void |
multipleWritesCapturedExceptions()
Tests writing multiple times with exceptions from each write.
|
void |
readCapturedExceptionsIsDestructive()
Reading captured exceptions twice in a row.
|
void |
setSystemLocaleBackToDefault() |
void |
setSystemLocaleToValueNotGerman() |
static void |
storeSystemLocale() |
void |
writeBadBeanUnorderedCaptureExceptions()
Writing a bad bean when exceptions are not thrown and the results are
unordered.
|
void |
writeBindByNameUnknownType()
Test of writing with @CsvBindByName attached to unknown type.
|
void |
writeBindByPositionUnknownType()
Test of writing with @CsvBindByPosition attached to unknown type.
|
void |
writeCustomByName()
Test of good data with custom converters and a header name mapping
strategy.
|
void |
writeCustomByPosition()
Test of good data with custom converters and a column position mapping
strategy.
|
void |
writeDerivedSubclass()
Writing a subclass with annotations in the subclass and the superclass.
|
void |
writeDerivedSuperclass()
Specifying a superclass, but writing a subclass.
|
void |
writeEmptyFieldWithConvertGermanToBooleanRequired()
Tests writing an empty field annotated with the custom converter
ConvertGermanToBoolean with
required set to true. |
void |
writeGetterMissing()
Tests of writing when getter is missing.
|
void |
writeGetterPrivate()
Tests writing when getter is private.
|
void |
writeManyFirstBeanIsBad()
Writing a bad bean at the beginning of a long list to trigger shutting
down the ExecutorService.
|
void |
writeMixedSingleMultipleBeans()
Test of writing a mixture of single beans and multiple beans.
|
void |
writeMultipleBeansOrdered()
Test of writing multiple beans at once when order counts.
|
void |
writeMultipleBeansUnordered()
Test of writing multiple beans at once when order doesn't matter.
|
void |
writeNullRequiredCustom()
Writing a required field with a custom converter that is null.
|
void |
writeNullRequiredDate()
Writing a required date field that is null.
|
void |
writeNullRequiredWrappedPrimitive()
Writing a required wrapped primitive field that is null.
|
void |
writeOptionalFieldsWithNull()
Test of writing optional fields whose values are null.
|
void |
writeOptionalNonContiguousField()
Test of writing an optional field with a column position not adjacent
to the other column positions.
|
void |
writeSingleBeanNoQuotes()
Test of writing a single bean.
|
void |
writeSingleOptionallyQuotedBean() |
void |
writeSingleOptionallyQuotedBeanWithCSVParser() |
void |
writeSingleOptionallyQuotedBeanWithPlainCSVWriter() |
void |
writeSingleQuotedBean() |
void |
writeSpecifiedStrategy()
Test of writing using a specified mapping strategy.
|
void |
writeWithoutAnnotations()
Test writing with no annotations.
|
@BeforeAll public static void storeSystemLocale()
@BeforeEach public void setSystemLocaleToValueNotGerman()
@BeforeEach public void createWriters()
@AfterEach public void setSystemLocaleBackToDefault()
@Test
public void writeSingleBeanNoQuotes()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeSingleOptionallyQuotedBean()
throws IOException,
com.opencsv.exceptions.CsvException
IOExceptioncom.opencsv.exceptions.CsvException@Test
public void writeSingleOptionallyQuotedBeanWithCSVParser()
throws IOException,
com.opencsv.exceptions.CsvException
IOExceptioncom.opencsv.exceptions.CsvException@Test
public void writeSingleOptionallyQuotedBeanWithPlainCSVWriter()
throws IOException,
com.opencsv.exceptions.CsvException
IOExceptioncom.opencsv.exceptions.CsvException@Test
public void writeSingleQuotedBean()
throws IOException,
com.opencsv.exceptions.CsvException
IOExceptioncom.opencsv.exceptions.CsvException@Test
public void writeMultipleBeansOrdered()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeMultipleBeansUnordered()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeMixedSingleMultipleBeans()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeOptionalFieldsWithNull()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeOptionalNonContiguousField()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeSpecifiedStrategy()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeBindByPositionUnknownType()
throws com.opencsv.exceptions.CsvException
com.opencsv.exceptions.CsvException - Never@Test
public void writeBindByNameUnknownType()
throws com.opencsv.exceptions.CsvException
com.opencsv.exceptions.CsvException - Never@Test
public void writeWithoutAnnotations()
throws com.opencsv.exceptions.CsvException
com.opencsv.exceptions.CsvException - Never@Test
public void writeDerivedSubclass()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeDerivedSuperclass()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeGetterMissing()
throws com.opencsv.exceptions.CsvException
com.opencsv.exceptions.CsvException - Never@Test
public void writeGetterPrivate()
throws com.opencsv.exceptions.CsvException
com.opencsv.exceptions.CsvException - Never@Test
public void writeNullRequiredWrappedPrimitive()
throws IOException,
com.opencsv.exceptions.CsvException,
NoSuchFieldException
IOException - Nevercom.opencsv.exceptions.CsvException - NeverNoSuchFieldException - Never@Test
public void writeNullRequiredCustom()
throws IOException,
com.opencsv.exceptions.CsvException,
NoSuchFieldException
IOException - Nevercom.opencsv.exceptions.CsvException - NeverNoSuchFieldException - Never@Test
public void writeManyFirstBeanIsBad()
throws IOException,
com.opencsv.exceptions.CsvException,
NoSuchFieldException
IOException - Nevercom.opencsv.exceptions.CsvException - NeverNoSuchFieldException - Never@Test
public void writeBadBeanUnorderedCaptureExceptions()
throws IOException,
com.opencsv.exceptions.CsvException,
NoSuchFieldException
IOException - Nevercom.opencsv.exceptions.CsvException - NeverNoSuchFieldException - Never@Test
public void writeNullRequiredDate()
throws IOException,
com.opencsv.exceptions.CsvException,
NoSuchFieldException
IOException - Nevercom.opencsv.exceptions.CsvException - NeverNoSuchFieldException - Never@Test
public void readCapturedExceptionsIsDestructive()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void multipleWritesCapturedExceptions()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void bindCustomConverterToWrongDataType()
throws com.opencsv.exceptions.CsvException
com.opencsv.exceptions.CsvException - Never@Test
public void writeCustomByPosition()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeCustomByName()
throws IOException,
com.opencsv.exceptions.CsvException
IOException - Nevercom.opencsv.exceptions.CsvException - Never@Test
public void writeEmptyFieldWithConvertGermanToBooleanRequired()
throws IOException,
com.opencsv.exceptions.CsvException
ConvertGermanToBoolean with
required set to true.IOException - Nevercom.opencsv.exceptions.CsvException - NeverCopyright © 2005–2025. All rights reserved.