@Override
    protected boolean isNewMigration(NoSqlMigration noSqlMigration) {
        Document migration = migrationCollection.find(eq(toMongoId(Migrations.FIELD_ID), noSqlMigration.getClassName())).first();
        return migration == null;
    }
@Test
    void testMigrationsHappyPath() {
        MongoDBCreator mongoDBCreator = new MongoDBCreator(mongoClient(), MongoDBStorageProvider.DEFAULT_DB_NAME);

        assertThat(mongoDBCreator.isNewMigration(new NoSqlMigrationByClass(M001_CreateJobCollection.class))).isTrue();
        assertThat(mongoDBCreator.isNewMigration(new NoSqlMigrationByClass(M002_CreateRecurringJobCollection.class))).isTrue();

        assertThatCode(mongoDBCreator::runMigrations).doesNotThrowAnyException();
        assertThatCode(mongoDBCreator::runMigrations).doesNotThrowAnyException();

        assertThat(mongoDBCreator.isNewMigration(new NoSqlMigrationByClass(M001_CreateJobCollection.class))).isFalse();
        assertThat(mongoDBCreator.isNewMigration(new NoSqlMigrationByClass(M002_CreateRecurringJobCollection.class))).isFalse();
    }