### Question:
DefaultDBClearer implements DBClearer { public void clearDatabase() { StructureUtils.assertItemsToPreserveExist(databases, itemsToPreserve); executedScriptInfoSource.clearAllExecutedScripts(); constraintsDisabler.disableReferentialConstraints(); for (Database database : databases.getDatabases()) { if (database == null) { continue; } clearDatabase(database); } } DefaultDBClearer(Databases databases, 
    		Set<DbItemIdentifier> itemsToPreserve, 
    		Set<DbItemIdentifier> itemsToPurge, 
    		ConstraintsDisabler constraintsDisabler, 
    		ExecutedScriptInfoSource executedScriptInfoSource); void clearDatabase();  }### Answer:
@Test void clearTables() { assertEquals(2, defaultDatabase.getTableNames().size()); defaultDBClearer.clearDatabase(); assertTrue(defaultDatabase.getTableNames("PUBLIC").isEmpty()); }
@Test void clearViews() { assertEquals(2, defaultDatabase.getViewNames().size()); defaultDBClearer.clearDatabase(); assertTrue(defaultDatabase.getViewNames().isEmpty()); }
@Test void clearMaterializedViews() { if (!defaultDatabase.supportsMaterializedViews()) { logger.warn("Current dialect does not support materialized views. Skipping test."); return; } assertEquals(2, defaultDatabase.getMaterializedViewNames().size()); defaultDBClearer.clearDatabase(); assertTrue(defaultDatabase.getMaterializedViewNames().isEmpty()); }
@Test void clearSynonyms() { if (!defaultDatabase.supportsSynonyms()) { logger.warn("Current dialect does not support synonyms. Skipping test."); return; } assertEquals(2, defaultDatabase.getSynonymNames().size()); defaultDBClearer.clearDatabase(); assertTrue(defaultDatabase.getSynonymNames().isEmpty()); }
@Test void clearSequences() { if (!defaultDatabase.supportsSequences()) { logger.warn("Current dialect does not support sequences. Skipping test."); return; } assertEquals(2, defaultDatabase.getSequenceNames().size()); defaultDBClearer.clearDatabase(); assertTrue(defaultDatabase.getSequenceNames().isEmpty()); }