File tree Expand file tree Collapse file tree 3 files changed +557
-1120
lines changed
Expand file tree Collapse file tree 3 files changed +557
-1120
lines changed Original file line number Diff line number Diff line change 3737 run : |
3838 npm run e2e
3939 npm run e2e:coverage:report
40-
41-
42- - name : Upload coverage reports
43- if : always()
44- uses : actions/upload-artifact@v4
45- with :
46- name : coverage-e2e
47- path : coverage-e2e/
48- retention-days : 30
49-
50- - name : Upload Playwright report
51- if : always()
52- uses : actions/upload-artifact@v4
53- with :
54- name : playwright-report
55- path : playwright-report/
56- retention-days : 30
57-
58- - name : Comment coverage on PR
59- if : github.event_name == 'pull_request'
60- uses : actions/github-script@v7
61- with :
62- script : |
63- const fs = require('fs');
64- const coveragePath = 'coverage-e2e/lcov-report/index.html';
65-
66- if (!fs.existsSync(coveragePath)) {
67- console.log('Coverage report not found');
68- return;
69- }
70-
71- // Read the summary from the test output
72- const summary = `## Frontend E2E Test Coverage
73-
74- Coverage reports have been generated and uploaded as artifacts.
75-
76- Download the artifacts from this workflow run to view the full HTML coverage report.
77- `;
78-
79- github.rest.issues.createComment({
80- issue_number: context.issue.number,
81- owner: context.repo.owner,
82- repo: context.repo.repo,
83- body: summary
84- });
You can’t perform that action at this time.
0 commit comments