csaf-poc / csaf_webview

Web app (module) to display a CSAF 2 document and to browse CSAF 2 ROLIE feeds. ⚠️ The web demo is often not allowed to access servers:
https://csaf-poc.github.io/csaf_webview/
1 stars 3 forks source link

Add github action that creates a comment with coverage report on pull request #3

Closed JanHoefelmeyer closed 1 year ago

JanHoefelmeyer commented 1 year ago

Solves https://github.com/csaf-poc/csaf_webview/issues/2

Adds the vitest coverage check to any PR. Check can be configured via https://github.com/csaf-poc/csaf_webview/blob/main/vite.config.ts.

Action will start the check when a Pull Request is created, then the bot will comment the result. This PR contains an example.

github-actions[bot] commented 1 year ago

Coverage Report

Status Category Percentage Covered / Total
🟢 Lines 89.58% / 60% 43 / 48
🟢 Statements 91.07% / 60% 51 / 56
🟢 Functions 100% / 60% 13 / 13
🟢 Branches 88.63% / 60% 39 / 44
File CoverageNo changed files found.
Generated in workflow #1
ThomasJunk commented 1 year ago

LGTM and seems to work.