Fix case where no tags does not trigger false

This commit is contained in:
Webber
2020-05-01 20:19:25 +02:00
committed by Webber Takken
parent e9514b4e37
commit 34e4b86924
4 changed files with 36 additions and 12 deletions

View File

@@ -44,5 +44,13 @@ describe('System', () => {
expect(info).toHaveBeenCalledTimes(2);
expect(info).toHaveBeenLastCalledWith('3\n');
});
it('allows pipes using buffer', async () => {
await expect(
System.run('sh', undefined, {
input: Buffer.from('git tag --list --merged HEAD | grep v[0-9]* | wc -l'),
}),
).resolves.toBeParsableToANumber();
});
});
});