@Test
public void testGetMigration() {
Migrations migrations = new Migrations(new MigrationImpl(1, 2), new MigrationImpl(2, 3), new MigrationImpl(3, 4));
Migration migration = migrations.getMigration(2, 4);
assertEquals(ChainedMigration.class, migration.getClass());
ChainedMigration chainedMigration = (ChainedMigration) migration;
assertEquals(2, chainedMigration.getMigrations().size());
assertEquals(migrations.getMigrations().get(1), chainedMigration.getMigrations().get(0));
migration = migrations.getMigration(2, 3);
assertFalse(migration instanceof ChainedMigration);
assertEquals(migrations.getMigrations().get(1), migration);
}