Examples of workingCopy()


Examples of com.aragost.javahg.Repository.workingCopy()

        Changeset backoutCs = commitCmd.execute();

        BackoutCommand.on(repo).rev(backoutCs.getNode())
                .message("BackoutMerge").user("user").execute();

        Assert.assertEquals(backoutCs, repo.workingCopy().getParent1().getParent1());
        Assert.assertEquals(null, repo.workingCopy().getParent2());       
        Assert.assertEquals(null, repo.workingCopy().getParent1().getParent2());

        commitCmd.execute();
View Full Code Here

Examples of com.aragost.javahg.Repository.workingCopy()

        BackoutCommand.on(repo).rev(backoutCs.getNode())
                .message("BackoutMerge").user("user").execute();

        Assert.assertEquals(backoutCs, repo.workingCopy().getParent1().getParent1());
        Assert.assertEquals(null, repo.workingCopy().getParent2());       
        Assert.assertEquals(null, repo.workingCopy().getParent1().getParent2());

        commitCmd.execute();

        Assert.assertEquals("bar", readFile("b"));
View Full Code Here

Examples of com.aragost.javahg.Repository.workingCopy()

        BackoutCommand.on(repo).rev(backoutCs.getNode())
                .message("BackoutMerge").user("user").execute();

        Assert.assertEquals(backoutCs, repo.workingCopy().getParent1().getParent1());
        Assert.assertEquals(null, repo.workingCopy().getParent2());       
        Assert.assertEquals(null, repo.workingCopy().getParent1().getParent2());

        commitCmd.execute();

        Assert.assertEquals("bar", readFile("b"));
        Assert.assertEquals(3, LogCommand.on(repo).execute().size());
View Full Code Here

Examples of com.aragost.javahg.Repository.workingCopy()

        Assert.assertFalse(BisectCommand.on(repo).bad().execute().isComplete());

        BisectResult result = null;

        do {
            if (repo.workingCopy().getParent1().getRevision() < target.getRevision()) {
                result = BisectCommand.on(repo).good().execute();
            } else {
                result = BisectCommand.on(repo).bad().execute();
            }
        }
View Full Code Here

Examples of com.aragost.javahg.Repository.workingCopy()

        Repository repo = getTestRepository();
        Changeset base = createChangeset();
        Changeset parent2 = createChangeset();
        update(base);
        Changeset parent1 = createChangeset();
        ConflictResolvingContext ms = repo.workingCopy().merge(parent2);
        Assert.assertEquals(parent1, ms.getLocal());
        Assert.assertEquals(parent2, ms.getRemote());
        Assert.assertEquals(base, ms.getBase());
    }
View Full Code Here

Examples of com.aragost.javahg.Repository.workingCopy()

        writeFile("a", "");
        Changeset base = commit();
        writeFile("a", "a");
        Changeset p2 = commit();
        update(base);
        repo.workingCopy().remove("a");
        Changeset p1 = commit();

        ConflictResolvingContext ms = repo.workingCopy().merge(p2);
        Assert.assertEquals(1, ms.getKeepDeleteConflicts().size());
        KeepDeleteConflict keepDeleteConflict = ms.getKeepDeleteConflicts().iterator().next();
View Full Code Here

Examples of com.aragost.javahg.Repository.workingCopy()

        Changeset p2 = commit();
        update(base);
        repo.workingCopy().remove("a");
        Changeset p1 = commit();

        ConflictResolvingContext ms = repo.workingCopy().merge(p2);
        Assert.assertEquals(1, ms.getKeepDeleteConflicts().size());
        KeepDeleteConflict keepDeleteConflict = ms.getKeepDeleteConflicts().iterator().next();
        Assert.assertEquals(KeepDeleteConflict.State.KEEP, keepDeleteConflict.getState());
        Assert.assertEquals("a", keepDeleteConflict.getFilename());
        Assert.assertEquals(p2, keepDeleteConflict.getKeepParent());
View Full Code Here

Examples of com.aragost.javahg.Repository.workingCopy()

        Assert.assertEquals(KeepDeleteConflict.State.KEEP, keepDeleteConflict.getState());
        Assert.assertEquals("a", keepDeleteConflict.getFilename());
        Assert.assertEquals(p2, keepDeleteConflict.getKeepParent());

        update(p2);
        ms = repo.workingCopy().merge(p1);
        Assert.assertEquals(1, ms.getKeepDeleteConflicts().size());
        keepDeleteConflict = ms.getKeepDeleteConflicts().iterator().next();
        Assert.assertEquals(KeepDeleteConflict.State.KEEP, keepDeleteConflict.getState());
        Assert.assertEquals("a", keepDeleteConflict.getFilename());
        Assert.assertEquals(p2, keepDeleteConflict.getKeepParent());
View Full Code Here

Examples of com.aragost.javahg.Repository.workingCopy()

        File a = getTestRepository().file("a");
        Assert.assertTrue(a.exists());
        keepDeleteConflict.delete();
        Assert.assertFalse(a.exists());
        StatusResult status1 = repo.workingCopy().status();
        Assert.assertArrayEquals(new String[] { "a" }, status1.getRemoved().toArray());
        StatusResult status2 = repo.workingCopy().parent2Status();
        Assert.assertTrue(status2.getRemoved().isEmpty());

        keepDeleteConflict.keep();
View Full Code Here

Examples of com.aragost.javahg.Repository.workingCopy()

        Assert.assertTrue(a.exists());
        keepDeleteConflict.delete();
        Assert.assertFalse(a.exists());
        StatusResult status1 = repo.workingCopy().status();
        Assert.assertArrayEquals(new String[] { "a" }, status1.getRemoved().toArray());
        StatusResult status2 = repo.workingCopy().parent2Status();
        Assert.assertTrue(status2.getRemoved().isEmpty());

        keepDeleteConflict.keep();
        Assert.assertTrue(a.exists());
        status1 = repo.workingCopy().status();
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.