test: fix tests failing in ci

This commit is contained in:
Aleksey Kulikov 2021-10-27 17:35:20 +03:00
parent 7f0cd86e72
commit 0e329bd2b1
22 changed files with 291 additions and 257 deletions

View file

@ -94,6 +94,7 @@ void main() {
test('successfully packs with default arguments', () {
final odb = repo.odb;
final objectsCount = odb.objects.length;
Directory('${repo.workdir}.git/objects/pack/').createSync();
final writtenCount = repo.pack();
expect(writtenCount, objectsCount);
@ -120,6 +121,7 @@ void main() {
});
test('successfully packs with provided packDelegate', () {
Directory('${repo.workdir}.git/objects/pack/').createSync();
void packDelegate(PackBuilder packBuilder) {
final branches = repo.branches;
for (final branch in branches) {