Search in sources :

Example 11 with DiffOutputControl

use of liquibase.diff.output.DiffOutputControl in project liquibase by liquibase.

the class AbstractIntegrationTest method generateChangeLog_noChanges.

@Test
public void generateChangeLog_noChanges() throws Exception {
    if (database == null) {
        return;
    }
    runCompleteChangeLog();
    DiffResult diffResult = DiffGeneratorFactory.getInstance().compare(database, database, new CompareControl());
    DiffToChangeLog changeLogWriter = new DiffToChangeLog(diffResult, new DiffOutputControl(false, false, false, null));
    List<ChangeSet> changeSets = changeLogWriter.generateChangeSets();
    assertEquals(0, changeSets.size());
}
Also used : CompareControl(liquibase.diff.compare.CompareControl) DiffOutputControl(liquibase.diff.output.DiffOutputControl) DiffToChangeLog(liquibase.diff.output.changelog.DiffToChangeLog) DiffResult(liquibase.diff.DiffResult) ChangeSet(liquibase.changelog.ChangeSet) Test(org.junit.Test)

Aggregations

DiffOutputControl (liquibase.diff.output.DiffOutputControl)11 DiffToChangeLog (liquibase.diff.output.changelog.DiffToChangeLog)8 DiffResult (liquibase.diff.DiffResult)6 CompareControl (liquibase.diff.compare.CompareControl)6 Database (liquibase.database.Database)5 IOException (java.io.IOException)4 ParserConfigurationException (javax.xml.parsers.ParserConfigurationException)4 CatalogAndSchema (liquibase.CatalogAndSchema)4 Liquibase (liquibase.Liquibase)4 Test (org.junit.Test)4 PrintStream (java.io.PrintStream)3 StandardObjectChangeFilter (liquibase.diff.output.StandardObjectChangeFilter)3 DatabaseException (liquibase.exception.DatabaseException)3 LiquibaseException (liquibase.exception.LiquibaseException)3 DatabaseSnapshot (liquibase.snapshot.DatabaseSnapshot)3 SnapshotControl (liquibase.snapshot.SnapshotControl)3 UnsupportedEncodingException (java.io.UnsupportedEncodingException)2 DiffToReport (liquibase.diff.output.report.DiffToReport)2 UnexpectedLiquibaseException (liquibase.exception.UnexpectedLiquibaseException)2 ValidationFailedException (liquibase.exception.ValidationFailedException)2