// update files on master
commitFile(FILE1, "blah", "master");
RevCommit c4 = commitFile("file2", "more change", "master");
RebaseResult res = git.rebase().setUpstream("HEAD~2")
.runInteractively(new InteractiveHandler() {
public void prepareSteps(List<RebaseTodoLine> steps) {
steps.add(0, new RebaseTodoLine(
"# Comment that should not be processed"));
}
public String modifyCommitMessage(String commit) {
fail("modifyCommitMessage() was not expected to be called");
return commit;
}
}).call();
assertEquals(RebaseResult.Status.FAST_FORWARD, res.getStatus());
RebaseResult res2 = git.rebase().setUpstream("HEAD~2")
.runInteractively(new InteractiveHandler() {
public void prepareSteps(List<RebaseTodoLine> steps) {
try {
// delete RevCommit c4
steps.get(0).setAction(Action.COMMENT);
} catch (IllegalTodoFileModification e) {