Clean up after tests
This commit is contained in:
parent
38c90ed08f
commit
fbc34f818a
36
.github/workflows/ci.yml
vendored
36
.github/workflows/ci.yml
vendored
@ -46,21 +46,21 @@ jobs:
|
||||
})
|
||||
const actual = child_process.execSync(`curl -Ls ${release.data.assets[0].browser_download_url}`)
|
||||
assert.deepStrictEqual(expected, actual)
|
||||
# - name: Clean up
|
||||
# if: ${{ always() }}
|
||||
# uses: actions/github-script@v2
|
||||
# with:
|
||||
# github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
# script: |
|
||||
# const release = await github.repos.getReleaseByTag({
|
||||
# ...context.repo,
|
||||
# tag: "ci-test-${{ matrix.os }}",
|
||||
# })
|
||||
# await github.repos.deleteRelease({
|
||||
# ...context.repo,
|
||||
# release_id: release.data.id,
|
||||
# })
|
||||
# await github.git.deleteRef({
|
||||
# ...context.repo,
|
||||
# ref: "ci-test-${{ matrix.os }}",
|
||||
# })
|
||||
- name: Clean up
|
||||
if: ${{ always() }}
|
||||
uses: actions/github-script@v2
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
script: |
|
||||
const release = await github.repos.getReleaseByTag({
|
||||
...context.repo,
|
||||
tag: "ci-test-${{ matrix.os }}",
|
||||
})
|
||||
await github.repos.deleteRelease({
|
||||
...context.repo,
|
||||
release_id: release.data.id,
|
||||
})
|
||||
await github.git.deleteRef({
|
||||
...context.repo,
|
||||
ref: "ci-test-${{ matrix.os }}",
|
||||
})
|
||||
|
1
dist/index.js
vendored
1
dist/index.js
vendored
@ -2245,7 +2245,6 @@ function upload_to_release(release, file, asset_name, tag, overwrite, octokit) {
|
||||
core.debug(`No pre-existing asset called ${asset_name} found in release ${tag}. All good.`);
|
||||
}
|
||||
core.debug(`Uploading ${file} to ${asset_name} in release ${tag}.`);
|
||||
console.log(file_bytes.toString());
|
||||
yield octokit.repos.uploadReleaseAsset({
|
||||
url: release.data.upload_url,
|
||||
name: asset_name,
|
||||
|
Loading…
Reference in New Issue
Block a user