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>
This commit is contained in:
CrazyMax
2020-05-07 02:15:24 +02:00
committed by GitHub
parent 88f1da8c86
commit 6c7b10c265
16 changed files with 269 additions and 23170 deletions
+16
View File
@@ -0,0 +1,16 @@
import * as github from '../src/github';
describe('github', () => {
it('returns latest GoReleaser GitHub release', async () => {
const release = await github.getRelease('latest');
console.log(release);
expect(release).not.toBeNull();
expect(release?.tag_name).not.toEqual('');
});
it('returns v0.117.0 GoReleaser GitHub release', async () => {
const release = await github.getRelease('v0.117.0');
console.log(release);
expect(release).not.toBeNull();
expect(release?.tag_name).toEqual('v0.117.0');
});
});