Skip to content

twyle/oryks-code-coverage

Repository files navigation

oryks-code-coverage

This GitHub Action shows Code Coverage for a given project.

Custom badge security: bandit Imports: isort made-with-python GitHub license Medium Visual Studio Code Ubuntu

This GitHub Action shows code Coverage for a given python project using Pytest Coverage. To use this action, your project must have tests written using pytest and stored in a test folder. You can read about how it was developed over at How To Create a GitHub Action that Shows Code Coverage using Pytest

Inputs

codedirectory

Required The directory containing the source code. Default ".".

testdirectory

Required The directory containing the tests. Default "tests\".

pycovconfigfile

Optional The pycov configuration file Default ".coveragerc".

pytestconfigfile

Optional The pytest configuration file. Default "setup.cfg".

github_token

Required The GitHub Token. Default "${{ github.token }}".

github_token

Required The GitHub Token. Default ".".

oryks_token

Required The Code Coverage. Default "."

Outputs

testcoverage

The Test coverage

Example usage

- name: oryks code coverage action
  id: selftest
  uses: twyle/oryks-code-coverage@v0.17.1
  with:
    codedirectory: src/
    testdirectory: tests/
    github_token: ${{ github.token }}
    oryks_token: ${{ secrets.ORYKS_TOKEN }}

- name: action output
  run: |
    echo "${{ steps.selftest.outputs.testcoverage }}

About

Github actionto show code coverage.

Resources

License

Stars

Watchers

Forks

Packages

No packages published