Skip to content

Commit

Permalink
fix: clear core.summary mock
Browse files Browse the repository at this point in the history
  • Loading branch information
brenoepics committed Sep 29, 2024
1 parent 15e5a9e commit 4878fcf
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 32 deletions.
28 changes: 0 additions & 28 deletions __tests__/comments.test.ts

This file was deleted.

5 changes: 2 additions & 3 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -144854,14 +144854,13 @@ async function deleteOldComments(octokit, owner, repo, pull_number) {
});
}
}
async function commentOnPullRequest(commentBody) {
async function commentOnPullRequest(commentBody, token = core.getInput("github-token")) {
if (!lib_github.context.payload.pull_request) {
throw new Error("No pull request found in the context!");
}
if (core.getInput("github-token") === "") {
if (token === "") {
throw new Error("Could not add a comment to pull request because github-token is missing!");
}
const token = core.getInput("github-token");
const octokit = lib_github.getOctokit(token);
const { owner, repo } = lib_github.context.repo;
const pull_number = lib_github.context.payload.pull_request.number;
Expand Down
2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

0 comments on commit 4878fcf

Please sign in to comment.