Skip to content

Commit 9512e8d

Browse files
committed
ci: fix running cypress tests on PR closes #133
1 parent b020748 commit 9512e8d

File tree

2 files changed

+12
-17
lines changed

2 files changed

+12
-17
lines changed

.github/actions/set-pr-status/entrypoint.js

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,15 @@ const tools = new Toolkit()
44

55
const { owner, repo } = tools.context.repo
66
const { sha } = tools.context
7-
const { status, message, context } = tools.inputs
7+
const { state, description } = tools.inputs
88

99
tools.github.repos
10-
.createStatus({
10+
.createCommitStatus({
1111
owner,
1212
repo,
1313
sha,
14-
state: status,
15-
description: message,
16-
context,
14+
state,
15+
description,
1716
target_url: `https://www.github.com/${owner}/${repo}/commit/${sha}/checks`,
1817
})
1918
.then(() => {

.github/workflows/e2e-tests.yml

Lines changed: 8 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,8 @@ jobs:
1515
env:
1616
GITHUB_TOKEN: ${{ secrets.GITHUB }}
1717
with:
18-
context: e2e tests
19-
status: pending
20-
message: Waiting for deployment
18+
state: pending
19+
description: Waiting for E2E
2120

2221
run_tests:
2322
name: Run E2E tests on deployment success
@@ -36,9 +35,8 @@ jobs:
3635
env:
3736
GITHUB_TOKEN: ${{ secrets.GITHUB }}
3837
with:
39-
context: e2e tests
40-
status: pending
41-
message: E2E tests are running
38+
state: pending
39+
description: E2E tests are running
4240

4341
- name: Install dependencies
4442
run: yarn
@@ -52,16 +50,14 @@ jobs:
5250
env:
5351
GITHUB_TOKEN: ${{ secrets.GITHUB }}
5452
with:
55-
context: e2e tests
56-
status: success
57-
message: All tests are passed
53+
state: success
54+
description: All tests are passed
5855

5956
- name: Set status to "failure"
6057
if: failure()
6158
uses: ./.github/actions/set-pr-status
6259
env:
6360
GITHUB_TOKEN: ${{ secrets.GITHUB }}
6461
with:
65-
context: e2e tests
66-
status: failure
67-
message: Some tests are failed
62+
state: failure
63+
description: Some tests are failed

0 commit comments

Comments
 (0)