rcmdnk/Python Test Action
GitHub Action for Python (poetry/uv, pytest with coverage, linters with prek/pre-commit)
View on GitHubTrust Signals
- Scorecard Score
- Scorecard 2–4scored Jul 6, 2026
- Maintenance Recency
- Activelast commit May 7, 2026
- License
- Apache 2.0
Pinned Snippet
uses: rcmdnk/python-action@a30ddf2744ffef4d288bb6e8bec7e5825c37f657 # v3.1.0tags can be moved; commit SHAs can't. why a SHA?
Inputs
| name | description | required | default |
|---|---|---|---|
| checkout | Set 1 to run checkout. | yes | 1 |
| post-checkout-command | Optional shell command(s) to run right after checkout. Multiple commands can be passed as a multi-line string. | no | "" |
| private-repo-app-client-id | GitHub App Client ID for accessing private GitHub repositories. If set together with private-repo-app-private-key, private-repo-app-owner, and private-repo-app-repositories, a GitHub App token is generated and used to rewrite git URLs so that private GitHub repositories can be accessed during dependency installation. | no | "" |
| private-repo-app-private-key | Private key of the GitHub App used to access private GitHub repositories. Used together with private-repo-app-client-id. | no | "" |
| private-repo-app-owner | GitHub organization or user where the GitHub App used for private repository access is installed. Used to scope the generated GitHub App token. | no | "" |
| private-repo-app-repositories | Private GitHub repositories to scope the generated GitHub App token to. One repository name per line. | no | "" |
| private-repo-app-debug | Set 1 to print sanitized git config and run git ls-remote tests after configuring the GitHub App token for private repository access. | no | 0 |
| setup-python | Set 1 to run setup-python. | yes | 1 |
| python-version | `python-version` for setup-python. | yes | 3.12 |
| setup-type | Python environment setup type (poetry, uv or pip). | yes | poetry |
| setup-option | Additional options for python environment setup. | yes | "" |
| pytest | Set 1 to run pytest. | yes | 1 |
| pytest-tests-path | Path to the directory of the test files. | yes | tests/ |
| pytest-ignore | Comma separated test file names which are excluded from the pytest. | yes | "" |
| pytest-separate-benchmark | Set 1 to run benchmark tests separately (execute only once at the main test, by --benchmark-disable) and show the benchmark results in the summary (need pytest-benchmark). | yes | 0 |
| coverage | Set 1 to check coverage for pytest (pytest-cov will be installed if not installed). | yes | 1 |
| coverage-cov-path | Path to check coverage. | yes | "" |
| pytest-cov-path | Path to check coverage (alternative to coverage-cov-path, to keep backward compatibility). | yes | "" |
| pytest-opt | Additional options for pytest. | yes | "" |
| coverage-push | Set 1 to push the coverage result to coverage branch. | yes | 0 |
| coverage-push-condition | Condition to push the coverage. This will be shown in the README if it is not empty. | yes | "" |
| github_token | Token to push the coverage branch. | yes | ${{ github.token }} |
| pre-commit | Set 1 to run pre-commit. | yes | 0 |
| prek | Set 1 to run prek. | yes | 0 |
| tmate | Set 1 to run tmate. | yes | 0 |
Outputs
| name | description |
|---|---|
| pytest | pytest status |
| pre_commit | pre-commit status |
| coverage | Coverage Percantage |
| color | Coverage Color |
| warnings | Coverage Warnings |
| errors | Coverage Errors |
| failures | Coverage Failures |
| skipped | Coverage Skipped |
| tests | Coverage Tests |
| time | Coverage Time |
| notSuccessTestInfo | Not Success Test Info |