refactor: use ffi Arena for resource management

This commit is contained in:
Aleksey Kulikov 2021-08-25 18:33:17 +03:00
parent d0bb7aaa0f
commit 747996b40c
17 changed files with 629 additions and 582 deletions

View file

@ -214,6 +214,11 @@ void main() {
});
group('setHead', () {
late Reference head;
setUp(() => head = repo.head);
tearDown(() => head.free());
test('successfully sets head when target is reference', () {
expect(repo.head.name, 'refs/heads/master');
expect(repo.head.target.sha, lastCommit);