Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to get other metrics #2

Closed
emibcn opened this issue Sep 8, 2020 · 1 comment · Fixed by #4
Closed

Allow to get other metrics #2

emibcn opened this issue Sep 8, 2020 · 1 comment · Fixed by #4
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@emibcn
Copy link
Contributor

emibcn commented Sep 8, 2020

Allow the user to get a different metric than just elements. For example:

  • statements
  • conditionals
  • methods
  • etc.

Maybe adding a field for selecting that and then using it at PHP like:

$metricName = $argv[3] || 'elements';

# (...)

foreach ($metrics as $metric) {
    $totalElements += (int) $metric[$metricName];
    $checkedElements += (int) $metric['covered' . $metricName];
}
@johanvanhelden johanvanhelden added enhancement New feature or request good first issue Good for newcomers labels Sep 8, 2020
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 8, 2020
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 24, 2020
….yml`, parse new argument, test, documentation.
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 24, 2020
….yml`, parse new argument, test, documentation. - v2 - Fix typo (missing `}`)
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 24, 2020
….yml`, parse new argument, test, documentation. - v3 - Make `$metricToParse` a real optional argument wich defaults to `elements``)
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 24, 2020
….yml`, parse new argument, test, documentation. - v3 - Fix indentation
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 24, 2020
….yml`, parse new argument, test, documentation. - v3 - Make `$metricToParse` a real optional argument wich defaults to `elements``), using only `$argv` to ensure tests work
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 24, 2020
….yml`, parse new argument, test, documentation. - v3 - Fix indentation and "tables"
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 24, 2020
….yml`, parse new argument, test, documentation. - v3 - Fix indentation and "tables" - v2
@emibcn
Copy link
Contributor Author

emibcn commented Sep 24, 2020

Changed code to merge with current version.

Adds:

  • An input in action.yml
  • An optional 5th argument for the script which defaults to elements
  • An optional 2nd argument for fromXml which defaults to elements
  • Documentation in README
  • Some test

emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 25, 2020
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 25, 2020
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 25, 2020
emibcn added a commit to emibcn/gha-clover-test-coverage-check that referenced this issue Sep 25, 2020
johanvanhelden added a commit that referenced this issue Sep 25, 2020
Fix #2 - Allow to get other metrics
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants