feat(merge): add ability to cherry-pick commit

This commit is contained in:
Aleksey Kulikov 2021-09-09 15:40:05 +03:00
parent 63dabcdd2c
commit 659e69b1f2
3 changed files with 38 additions and 2 deletions

View file

@ -242,5 +242,15 @@ void main() {
theirCommit.free();
});
});
test('successfully cherry-picks commit', () {
final cherry = repo['5aecfa0fb97eadaac050ccb99f03c3fb65460ad4'] as Commit;
repo.cherryPick(cherry);
expect(repo.state, GitRepositoryState.cherrypick.value);
final index = repo.index;
expect(index.conflicts, isEmpty);
index.free();
});
});
}