Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

GitHub Action for python coverage publish & analysis

License

Notifications You must be signed in to change notification settings

pahrens-github/coverage

Open more actions menu
 
 

Repository files navigation

Python Cov: Python Coverage Reporter GitHub Action

🐍 parse and publish coverage xml to a PR, enforce coverage rate on new & modified files

Usage

Create a new workflow .yml file in the .github/workflows/ directory.

You can create a coverage report using $ pytest --cov-report xml:path/to/coverage.xml

Minimal Configuration

name: 'coverage'
on:
    pull_request:
        branches:
            - master
            - main
jobs:
    coverage:
        runs-on: ubuntu-latest
        steps:
          - name: Python Cov 
            uses: orgoro/coverage/v
            with:
                coverageFile: path/to/coverage.xml
                token: ${{ secrets.GITHUB_TOKEN }}

PR Message

message

Inputs

Input Optional Description Example
coverageFile path to python .xml coverage report ./path/to/coverage.xml
token your github token 🤫
thresholdAll the minimal average line coverage 0.8
thresholdNew the minimal average new files line coverage 0.9
thresholdModified the minimal average modified files line coverage 0.0

About

GitHub Action for python coverage publish & analysis

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 98.6%
  • JavaScript 1.4%
Morty Proxy This is a proxified and sanitized view of the page, visit original site.