Unverified Commit 124c35d3 authored by per1234's avatar per1234 Committed by GitHub

[skip changelog] Enable Codecov reports on pull requests (#1783)

* [skip changelog] Revert "codecov: Disable pull request comments"

This reverts commit 5c9eee34.

Codecov will now automatically comment on pull requests to provide a report of the code coverage impact that would
result from the proposed changes.

These comments are valuable for several reasons:

- Brings test deficiencies to the contributor's attention
- Encourages contributors to improve PRs that originally had insufficient test coverage for the added code
- Facilitates the review process for the maintainers
- Increases awareness of code coverage trends in the project (the Codecov website is great for this, but likely rarely visited)

* [skip changelog] Add support to "Test Go" workflow for alternative Codecov configuration paths

For the sake of efficiency, the "Test Go" GitHub Actions workflow is configured to run only when relevant files are
modified. Since the workflow uploads code coverage data to Codecov, the Codecov configuration file is one of these files.

The standard filename for the Codecov configuration file is codecov.yml, and the workflow's path filter was configured
for that filename. It turns out an alternative filename is also recognized: .codecov.yml, which is used by this project.
Two subfolders are also supported in addition to the root of the repository as locations for the configuration file.

The workflow's paths filter was not configured for the alternative filename and locations, meaning the workflow would
not be triggered on change to the Codecov configuration in projects that use the alternative configuration file name or
locations.

The workflow's paths filter is hereby configured to recognize changes to any valid Codecov configuration file.
parent 4a4b784c
comment: off
ignore:
- rpc/**
- i18n/cmd/**
......
......@@ -11,7 +11,9 @@ on:
push:
paths:
- ".github/workflows/test-go-task.ya?ml"
- "codecov.ya?ml"
- ".github/.?codecov.ya?ml"
- "dev/.?codecov.ya?ml"
- ".?codecov.ya?ml"
- "go.mod"
- "go.sum"
- "Taskfile.ya?ml"
......@@ -20,7 +22,9 @@ on:
pull_request:
paths:
- ".github/workflows/test-go-task.ya?ml"
- "codecov.ya?ml"
- ".github/.?codecov.ya?ml"
- "dev/.?codecov.ya?ml"
- ".?codecov.ya?ml"
- "go.mod"
- "go.sum"
- "Taskfile.ya?ml"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment