Skip to content

Commit

Permalink
feat: add measure option (#183)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrexox authored Jul 13, 2023
1 parent cb1c78c commit 8e1cba0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ The action's step needs to run after your test suite has outputted an LCOV file.
| `compare-ref` | _optional_ | Branch name to compare coverage with. Specify if you want to always check coverage change for PRs against one branch. |
| `compare-sha` | _optional_ | Commit SHA to compare coverage with. |
| `debug` | _optional_ | Default: `false`. Set to `true` to enable debug logging. |
| `measure` | _optional_ | Default: `false`. Set to `true` to enable time time measurement logging. |

### Outputs:

Expand Down
7 changes: 6 additions & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ inputs:
description: 'Enable debug output'
required: false
default: false
measure:
description: 'Show execution time of parsing and reporting'
required: false
default: false
outputs:
coveralls-api-result:
description: 'Result status of Coveralls API post.'
Expand Down Expand Up @@ -100,7 +104,7 @@ runs:
- name: Done report
if: inputs.parallel-finished == 'true'
shell: bash
run: coveralls done ${{ inputs.debug == 'true' && '--debug' || '' }}
run: coveralls done ${{ inputs.debug == 'true' && '--debug' || '' }} ${{ inputs.measure == 'true' && '--measure' || '' }}
env:
COVERALLS_DEBUG: ${{ inputs.debug }}
COVERALLS_CARRYFORWARD_FLAGS: ${{ inputs.carryforward }}
Expand All @@ -117,6 +121,7 @@ runs:
run: >-
coveralls report
${{ inputs.debug == 'true' && '--debug' || '' }}
${{ inputs.measure == 'true' && '--measure' || '' }}
${{ inputs.allow-empty == 'true' && '--allow-empty' || '' }}
${{ inputs.base-path && format('--base-path {0}', inputs.base-path) || '' }}
${{ inputs.format && format('--format {0}', inputs.format) || '' }}
Expand Down

0 comments on commit 8e1cba0

Please sign in to comment.