Examples of HgRevertCommand


Examples of org.tmatesoft.hg.core.HgRevertCommand

//    hgRepo.getManifest().walk(2, 2, mr);
  }
 
 
  private void testRevert() throws Exception {
    HgRevertCommand cmd = new HgRevertCommand(hgRepo);
    cmd.file(Path.create("a.txt")).execute();
  }
View Full Code Here

Examples of org.tmatesoft.hg.core.HgRevertCommand

    eh.run("hg", "status", "-A");
    assertEquals("[sanity]", 1, statusParser.getModified().size());
    assertEquals("[sanity]", 2, statusParser.getClean().size());
    assertEquals("[sanity]", targetFile, statusParser.getModified().get(0));
   
    HgRevertCommand cmd = new HgRevertCommand(repo);
    cmd.file(targetFile).execute();
    statusParser.reset();
    eh.run("hg", "status", "-A");

    errorCollector.assertEquals(3, statusParser.getClean().size());
    errorCollector.assertTrue(statusParser.getClean().contains(targetFile));
View Full Code Here

Examples of org.tmatesoft.hg.core.HgRevertCommand

    assertTrue(fileA.isFile());
    assertFalse(fileB.isFile());
    assertTrue(fileC.isFile());
    RepoUtils.modifyFileAppend(fileA, "A2");
    RepoUtils.modifyFileAppend(fileC, "C1");
    new HgRevertCommand(hgRepo).changeset(1).file(fa).execute();
    errorCollector.assertTrue(new File(fileA.getParent(), fileA.getName() + ".orig").isFile());
    new HgCommitCommand(hgRepo).message("FOURTH").execute();
    // TODO merge and HgMergeCommand
   
    errorCollector.assertEquals(2, hgRepo.getFileNode(fa).getRevisionCount());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.