Skip to content

feat: Enhance unit test workflow with coverage reporting to Codecov - #508

Open
pallavt wants to merge 9 commits into
frappe:developfrom
pallavt:develop
Open

pallavt wants to merge 9 commits into
frappe:developfrom
pallavt:develop

Conversation

@pallavt

@pallavt pallavt commented Sep 18, 2026

Copy link
Copy Markdown

Summary

  • Emit coverage.xml from the unit test run (--cov-report=xml:coverage.xml, keeps term-missing).
  • Upload it via codecov/codecov-action@v7 with CODECOV_TOKEN (fail_ci_if_error: true).

Notes

  • Requires a CODECOV_TOKEN repo secret (Codecov dashboard → Settings).
  • CI-only change in .github/workflows/unit-tests.yml; no Python code touched.

@greptile-apps

greptile-apps Bot commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

The PR appears safe to merge.

Reviews (6) · Last reviewed commit: "fix: Update git diff command and improve..."

Comment thread .github/workflows/unit-tests.yml Outdated
@tanmoysrt

Copy link
Copy Markdown
Member

Can you instead use github ci and github bot to comment coverage info.

@pallavt

pallavt commented Sep 22, 2026

Copy link
Copy Markdown
Author

@tanmoysrt switched from Codecov to GitHub-native PR comment.

  • Removed codecov/codecov-action and the CODECOV_TOKEN requirement.

  • Now emits coverage.xml and posts/updates a coverage comment via orgoro/coverage@v3.3.1 (SHA-pinned) using only secrets.GITHUB_TOKEN.

  • Added permissions: contents: read, pull-requests: write; comment step runs on pull_request only.

No repo secrets or external service needed now.

Comment thread .github/scripts/coverage_comment.py Outdated
Comment thread .github/workflows/coverage-comment.yml Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants