{"id":20414518,"url":"https://github.com/codecov/test-results-action","last_synced_at":"2025-07-11T04:41:15.444Z","repository":{"id":224628304,"uuid":"761956558","full_name":"codecov/test-results-action","owner":"codecov","description":null,"archived":false,"fork":false,"pushed_at":"2025-03-11T17:52:24.000Z","size":1903,"stargazers_count":25,"open_issues_count":26,"forks_count":4,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-04-11T15:10:25.912Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/codecov.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-02-22T20:02:24.000Z","updated_at":"2025-03-26T08:35:43.000Z","dependencies_parsed_at":"2024-03-08T13:30:17.698Z","dependency_job_id":"e519965c-5aa3-49ea-8fce-67178f6c3f23","html_url":"https://github.com/codecov/test-results-action","commit_stats":null,"previous_names":["codecov/test-results-action"],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codecov%2Ftest-results-action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codecov%2Ftest-results-action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codecov%2Ftest-results-action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codecov%2Ftest-results-action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codecov","download_url":"https://codeload.github.com/codecov/test-results-action/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248600895,"owners_count":21131569,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-15T06:10:49.987Z","updated_at":"2025-07-11T04:41:15.437Z","avatar_url":"https://github.com/codecov.png","language":"TypeScript","readme":"## Usage\n\nCurrently, the Action will identify linux, macos, and windows runners. However, the Action may misidentify other architectures. The OS can be specified as\n- alpine\n- alpine-arm64\n- linux\n- linux-arm64\n- macos\n- windows\n\nInside your `.github/workflows/workflow.yml` file:\n\n```yaml\nsteps:\n- uses: actions/checkout@master\n- uses: codecov/test-results-action@v1\n  with:\n    fail_ci_if_error: true # optional (default = false)\n    files: ./junit1.xml,./junit2.xml # optional\n    flags: py3.11 # optional\n    name: codecov-umbrella # optional\n    token: ${{ secrets.CODECOV_TOKEN }} # required\n    verbose: true # optional (default = false)\n```\n\nThe Codecov token can also be passed in via environment variables:\n\n```yaml\nsteps:\n- uses: actions/checkout@master\n- uses: codecov/test-results-action@v1\n  with:\n    fail_ci_if_error: true # optional (default = false)\n    files: ./junit1.xml,./junit2.xml # optional\n    flags: python3.10 # optional\n    name: codecov-umbrella # optional\n    verbose: true # optional (default = false)\n  env:\n    CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}\n```\n\u003e [!IMPORTANT]\n\u003e This assumes that you've set your Codecov token inside *Settings \u003e Secrets* as `CODECOV_TOKEN`. If not, you can [get an upload token](https://docs.codecov.io/docs/frequently-asked-questions#section-where-is-the-repository-upload-token-found-) for your specific repo on [codecov.io](https://www.codecov.io).\n\u003e Keep in mind that secrets are *not* available to forks of repositories.\n\u003e View more information on tokenless uploads [here](https://docs.codecov.com/docs/codecov-tokens#uploading-without-a-token).\n\n\u003e [!NOTE]\n\u003e If you are using OIDC, you will need to set the `use_oidc` input to `true`, and make sure to add the following to your workflow file:\n\u003e  ```yaml\n\u003e  permissions:\n\u003e    id-token: write\n\u003e    contents: read\n\u003e  ...\n\u003e  steps:\n\u003e  - uses: codecov/test-results-action@v1\n\u003e    with:\n\u003e      use_oidc: true\n\u003e  ```\n\n## Arguments\n\nCodecov's Action supports inputs from the user. These inputs, along with their descriptions and usage contexts, are listed in the table below:\n\n| Input  | Description | Required |\n| :---       |     :---     |    :---:   |\n| `token` | Repository Codecov token. Used to authorize report uploads | *Required\n| `binary` | The file location of a pre-downloaded version of the CLI. If specified, integrity checking will be bypassed. | Optional\n| `codecov_yml_path` | Specify the path to the Codecov YML | Optional\n| `commit_parent` | Override to specify the parent commit SHA | Optional\n| `directory` | Directory to search for test result reports. | Optional\n| `disable_search` | Disable search for test result files. This is helpful when specifying what files you want to upload with the --file option. | Optional\n| `dry_run` | Don't upload files to Codecov | Optional\n| `env_vars` | Environment variables to tag the upload with (e.g. PYTHON \\| OS,PYTHON) | Optional\n| `exclude` | Folders to exclude from search | Optional\n| `fail_ci_if_error` | Specify whether or not CI build should fail if Codecov runs into an error during upload | Optional\n| `file` | Path to test result file to upload | Optional\n| `files` | Comma-separated list of files to upload | Optional\n| `flags` | Flag upload to group test results (e.g. py3.10 | py3.11 | py3.12) | Optional\n| `handle_no_reports_found` | Raise no exceptions when no test result reports found | Optional\n| `name` | User defined upload name. Visible in Codecov UI | Optional\n| `os` | Override the assumed OS. Options are linux \\| macos \\| windows \\| \\| linux-arm64 \\| alpine \\| alpine-arm64 . | Optional\n| `override_branch` | Specify the branch name | Optional\n| `override_build` | Specify the build number | Optional\n| `override_build_url` | The URL of the build where this is running | Optional\n| `override_commit` | Specify the commit SHA | Optional\n| `override_pr` | Specify the pull request number | Optional\n| `report_code` | The code of the report. If unsure, do not include | Optional\n| `root_dir` | Used when not in git/hg project to identify project root directory | Optional\n| `slug` | Specify the slug manually (Enterprise use) | Optional\n| `url` | Specify the base url to upload (Enterprise use) | Optional\n| `use_oidc` | Use OIDC to authenticate with Codecov | Optional\n| `verbose` | Specify whether the Codecov output should be verbose | Optional\n| `version` | Specify which version of the Codecov CLI should be used. Defaults to `latest` | Optional\n| `working-directory` | Directory in which to execute codecov.sh | Optional\n\n### Example `workflow.yml` with Codecov Action\n\n```yaml\nname: Example workflow for Codecov\non: [push]\njobs:\n  run:\n    runs-on: ${{ matrix.os }}\n    strategy:\n      matrix:\n        os: [ubuntu-latest, macos-latest, windows-latest]\n    env:\n      OS: ${{ matrix.os }}\n      PYTHON: '3.10'\n    steps:\n    - uses: actions/checkout@master\n    - name: Setup Python\n      uses: actions/setup-python@master\n      with:\n        python-version: 3.10\n    - name: Generate coverage and test result report\n      run: |\n        pip install pytest\n        pip install pytest-cov\n        pytest --cov=./ --cov-report=xml --junitxml=./junit.xml\n    - name: Upload test results to Codecov\n      if: ${{ !cancelled() }}\n      uses: codecov/test-results-action@v1\n      with:\n        files: ./junit.xml,!./cache\n        flags: python3.10\n        name: codecov-umbrella-test-results\n        token: ${{ secrets.CODECOV_TOKEN }}\n    - name: Upload coverage to Codecov\n      uses: codecov/codecov-action@v4\n      with:\n        directory: ./coverage/reports/\n        env_vars: OS,PYTHON\n        fail_ci_if_error: true\n        files: ./coverage1.xml,./coverage2.xml,!./cache\n        flags: unittests\n        name: codecov-umbrella\n        token: ${{ secrets.CODECOV_TOKEN }}\n        verbose: true\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodecov%2Ftest-results-action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodecov%2Ftest-results-action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodecov%2Ftest-results-action/lists"}