Package com.google.devtools.moe.client.database

Examples of com.google.devtools.moe.client.database.SubmittedMigration


    control.verify();

    // expected db at end of call to bookkeep
    DbStorage dbStorage = new DbStorage();
    dbStorage.addEquivalence(new Equivalence(new Revision("1", "int"), new Revision("1", "pub")));
    dbStorage.addMigration(new SubmittedMigration(
        new Revision("migrated_from", "int"), new Revision("migrated_to", "pub")));
    FileDb expectedDb = new FileDb(dbStorage);

    assertEquals(expectedDb.toJsonString(), fileSystem.fileToString(DB_FILE));
  }
View Full Code Here


    assertEquals(0, d.perform());
    control.verify();

    // expected db at end of call to bookkeep
    DbStorage dbStorage = new DbStorage();
    dbStorage.addMigration(new SubmittedMigration(
        new Revision("migrated_from", "int"), new Revision("migrated_to", "pub")));
    FileDb expectedDb = new FileDb(dbStorage);

    assertEquals(expectedDb.toJsonString(), fileSystem.fileToString(DB_FILE));
  }
View Full Code Here

    // expected db at end of call to bookkeep
    DbStorage dbStorage = new DbStorage();
    dbStorage.addEquivalence(new Equivalence(
        new Revision("migrated_from", "int"), new Revision("migrated_to", "pub")));
    dbStorage.addMigration(new SubmittedMigration(
        new Revision("migrated_from", "int"), new Revision("migrated_to", "pub")));
    FileDb expectedDb = new FileDb(dbStorage);

    assertEquals(expectedDb.toJsonString(), fileSystem.fileToString(DB_FILE));
  }
View Full Code Here

   * in the case of an inverse translation, translating the to-repo to the from-repo via the
   * forward-translator.
   */
  private static void processMigration(Revision fromRev, Revision toRev,
                                       Db db, ProjectContext context, boolean inverse) {
    SubmittedMigration migration = new SubmittedMigration(fromRev, toRev);
    if (!db.noteMigration(migration)) {
      AppContext.RUN.ui.info("Skipping bookkeeping of this SubmittedMigration "
          + "because it was already in the Db: " + migration);
      return;
    }
View Full Code Here

TOP

Related Classes of com.google.devtools.moe.client.database.SubmittedMigration

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.