This action comments a pull request with a HTML test coverage report.
The report is based on the lcov coverage report generated by your test runner.
Note that this action does not run any tests, but instead expects the tests to have been run by another action already.
Coverage after merging feat/test into master
| 71.63 |
|---|
Coverage Report
| File | % Stmts | % Branches | % Funcs | % Lines | |
|---|---|---|---|---|---|
| src | |||||
| cli.js | 0 | 0 | 0 | 0 | |
| comment.js | 73.33 | 66.67 | 100 | 75 | |
| html.js | 100 | 100 | 100 | 100 | |
| index.js | 0 | 0 | 0 | 0 | |
| lcov.js | 100 | 100 | 100 | 100 | |
| report.js | 94.12 | 82.05 | 100 | 98.61 | |
| tabulate.js | 97.27 | 95.92 | 100 | 97.96 | |
Coverage after merging feat/test into master
| 60.10 | (+30.54) 🟢 |
|---|
Coverage Report
| File | % Stmts | % Branches | % Funcs | % Lines | |
|---|---|---|---|---|---|
| src | |||||
| lcov.js | 0(-100) 🔴 | 0(-100) 🔴 | 0(-100) 🔴 | 0(-100) 🔴 | |
| report.js | 94.12(+94.12) 🟢 | 82.05(+82.05) 🟢 | 100(+100) 🟢 | 98.61(+98.61) 🟢 | |
Coverage after merging feat/test into master
| (+30.54) 🟢 |
|---|
Coverage Report
| File | % Stmts | % Branches | % Funcs | % Lines | Uncovered Lines |
|---|---|---|---|---|---|
| src | |||||
| lcov.js | 5–9, 11 | ||||
| report.js | 11, 53, 83–84, 139–140, 153, 157 | ||||
Github token used for posting the comment. To use the key provided by the GitHub action runner, use ${{ secrets.GITHUB_TOKEN }}.
The location of the lcov file to read the coverage report from. Defaults to ./coverage/lcov.info.
The location of the lcov file resulting from running the tests in the base branch. When this is set a diff of the coverage percentages is shown.
When set to true will show the uncovered lines column. Defaults to false;
When set to true will show a colored emoji if the coverage decreased 🔴 or increased 🟢, like "98.61(+2.61) 🟢 ". Defaults to false;
When set to true will show the old coverage result value, like: "94,65 98.61". Defaults to true;
When set to true will show the increase/decrease difference of the coverage, like: "98.61(+2.61)". Defaults to false;
uses: eberlitz/lcov-reporter-action@v0.2.30 with: github-token: ${{ secrets.GITHUB_TOKEN }} lcov-file: ./coverage/lcov.info base-file: ./coverage/base-lcov.info show-uncovered-lines: false show-color-emoji: true show-old-value-for-files: false show-increase-per-files: trueThe initial code is based on romeovs/lcov-reporter-action which was previously based on ziishaned/jest-reporter-action. I also got some ideas from hrgui/lcov-reporter-action;