|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.unitils.dbunit.util.DataSetAssert
public class DataSetAssert
Assert class that offers assert methods for testing things that are specific to DbUnit.
| Constructor Summary | |
|---|---|
DataSetAssert()
|
|
| Method Summary | |
|---|---|
protected void |
appendBestRowDifferences(TableDifference tableDifference,
StringBuilder result)
Appends the best matching row differences of the given table difference to the result |
protected void |
appendColumnNames(Row row,
StringBuilder result)
Appends the column names of the given row to the result |
protected void |
appendMissingRowDifferences(TableDifference tableDifference,
StringBuilder result)
Appends the missing rows of the given table difference to the result |
protected void |
appendMissingTableDifferences(SchemaDifference schemaDifference,
StringBuilder result)
Appends the missing tables of the given schema difference to the result |
protected void |
appendRow(Row row,
StringBuilder result)
Appends the values of the given row to the result |
protected void |
appendSchemaContent(Schema schema,
Schema actualSchema,
StringBuilder result)
Appends all rows and tables of the actual schema to the result. |
protected void |
appendTableDifferences(SchemaDifference schemaDifference,
StringBuilder result)
Appends the table differences of the given schema difference to the result |
protected void |
appendTableName(Schema schema,
Table table,
StringBuilder result)
Appends the schema and table name to the result |
void |
assertEqualDbUnitDataSets(String schemaName,
org.dbunit.dataset.IDataSet expectedDataSet,
org.dbunit.dataset.IDataSet actualDataSet)
Asserts that the given expected DbUnit data set is equal to the actual DbUnit data set. |
void |
assertEqualSchemas(Schema expectedSchema,
Schema actualSchema)
Asserts that the given expected schema is equal to the actual schema. |
protected String |
generateErrorMessage(SchemaDifference schemaDifference)
Formats the assertion failed message for the given difference. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DataSetAssert()
| Method Detail |
|---|
public void assertEqualSchemas(Schema expectedSchema,
Schema actualSchema)
throws AssertionError
expectedSchema - The expected schema, not nullactualSchema - The actual schema, not null
AssertionError - When the assertion fails.
public void assertEqualDbUnitDataSets(String schemaName,
org.dbunit.dataset.IDataSet expectedDataSet,
org.dbunit.dataset.IDataSet actualDataSet)
schemaName - The name of the schema that these data sets belong to, not nullexpectedDataSet - The expected data set, not nullactualDataSet - The actual data set, not null
AssertionError - When the assertion fails.protected String generateErrorMessage(SchemaDifference schemaDifference)
schemaDifference - The difference, not null
protected void appendMissingTableDifferences(SchemaDifference schemaDifference,
StringBuilder result)
schemaDifference - The difference, not nullresult - The result to append to, not null
protected void appendTableDifferences(SchemaDifference schemaDifference,
StringBuilder result)
schemaDifference - The difference, not nullresult - The result to append to, not null
protected void appendMissingRowDifferences(TableDifference tableDifference,
StringBuilder result)
tableDifference - The difference, not nullresult - The result to append to, not null
protected void appendBestRowDifferences(TableDifference tableDifference,
StringBuilder result)
tableDifference - The difference, not nullresult - The result to append to, not null
protected void appendColumnNames(Row row,
StringBuilder result)
row - The row, not nullresult - The result to append to, not null
protected void appendRow(Row row,
StringBuilder result)
row - The row, not nullresult - The result to append to, not null
protected void appendSchemaContent(Schema schema,
Schema actualSchema,
StringBuilder result)
schema - The expected schema, not nullactualSchema - The actual schema, not nullresult - The result to append to, not null
protected void appendTableName(Schema schema,
Table table,
StringBuilder result)
schema - The schema name, not nulltable - The table name, not nullresult - The result to append to, not null
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||