goreleaser-action/__tests__/git.test.ts
CrazyMax 6c7b10c265
feat: Use native GitHub Action tools to download assets and use GitHub API (#187)
* Use native GitHub Action tools to download assets and use GitHub API
* Fix unexpected output when tag not found
* Use GitHub Action exec
* Add screenshot

Co-authored-by: CrazyMax <crazy-max@users.noreply.github.com>
2020-05-07 02:15:24 +02:00

17 lines
478 B
TypeScript

import * as git from '../src/git';
describe('git', () => {
it('returns git tag', async () => {
const tag: string = await git.getTag();
console.log(tag);
expect(tag).not.toEqual('');
});
it('checks if tag is dirty', async () => {
expect(await git.isTagDirty('v1.3.1')).toBe(true);
});
it('returns short commit', async () => {
const commit: string = await git.getShortCommit();
console.log(commit);
expect(commit).not.toEqual('');
});
});