Skip to content

Commit

Permalink
Upgrade prettier (#114)
Browse files Browse the repository at this point in the history
* chore: add pre-commit tool

* fix: format codes
  • Loading branch information
kentaro-m authored Feb 19, 2023
1 parent 7eac648 commit 7fd684a
Show file tree
Hide file tree
Showing 7 changed files with 917 additions and 19 deletions.
1 change: 1 addition & 0 deletions .husky/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
_
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx lint-staged
4 changes: 2 additions & 2 deletions __tests__/handler.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ describe('handlePullRequest', () => {
let context: Context

beforeEach(async () => {
context = ({
context = {
eventName: '',
workflow: '',
action: '',
Expand Down Expand Up @@ -44,7 +44,7 @@ describe('handlePullRequest', () => {
},
sha: '',
ref: '',
} as unknown) as Context
} as unknown as Context
})

test('responds with an error if the webhook payload is not exist', async () => {
Expand Down
2 changes: 1 addition & 1 deletion __tests__/run.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ describe.only('run', () => {
})

test('succeeds the process', async () => {
coreMocked.getInput.mockImplementation(name => {
coreMocked.getInput.mockImplementation((name) => {
switch (name) {
case 'repo-token':
return 'token'
Expand Down
Loading

0 comments on commit 7fd684a

Please sign in to comment.