@Test public void testPullRebase() throws Exception { // Add a commit to the remote insertAndAdd(remoteGeogig.geogig, lines3); RevCommit commit = remoteGeogig.geogig.command(CommitOp.class).call(); expectedMaster.addFirst(commit); // Pull the commit PullOp pull = pullOp(); pull.setRebase(true).setAll(true).call(); Iterator<RevCommit> logs = localGeogig.geogig.command(LogOp.class).call(); List<RevCommit> logged = new ArrayList<RevCommit>(); for (; logs.hasNext();) { logged.add(logs.next()); } assertEquals(expectedMaster, logged); }
private PullResult pull(final GeogigTransaction context, final Remote remote) throws MergeConflictsException { String fetchSpec = remote.getFetchSpec(); PullResult pullResult = context.command(PullOp.class)// .setAll(false)// .setIncludeIndexes(true)// .setRemote(remote)// .addRefSpec(fetchSpec)// .setNoFastForward(true)// .setMessage(message)// .setProgressListener(getProgressListener())// .call(); return pullResult; }
@Test public void testPullRebase() throws Exception { // Add a commit to the remote insertAndAdd(remoteGeogig.geogig, lines3); RevCommit commit = remoteGeogig.geogig.command(CommitOp.class).call(); expectedMaster.addFirst(commit); // Pull the commit PullOp pull = pullOp(); pull.setRebase(true).setAll(true).call(); List<RevCommit> logged = log(localGeogig.repo); assertEquals(expectedMaster, logged); }
.setAll(fetchAll).addRefSpec(refSpec); try { final PullResult result = command.call();
pull.setAll(all).setRebase(rebase).setFullDepth(fulldepth); pull.setDepth(depth);
pull.setAll(all).setRebase(rebase).setFullDepth(fulldepth); pull.setDepth(depth); pull.setIncludeIndexes(withIndexes);
pull.setAll(all).setRebase(rebase).setFullDepth(fulldepth); pull.setDepth(depth); pull.setIncludeIndexes(withIndexes);