Skip to content

Conversation

@kraftbj
Copy link
Contributor

@kraftbj kraftbj commented Jan 14, 2026

Summary

  • Excludes the bin/ directory from Codecov coverage calculations

The bin/ directory contains CLI and infrastructure scripts that make HTTP requests to external APIs (GitHub REST/GraphQL). These are integration scripts that are inherently difficult to unit test without extensive HTTP mocking.

See #354 as an example - the codecov/patch check passes (confirming the testable parsing logic has coverage), but codecov/project fails because the CLI orchestration code in bin/ isn't covered.

Test plan

  • Verify Codecov no longer counts bin/ files toward project coverage

@github-actions
Copy link

github-actions bot commented Jan 14, 2026

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

Core Committers: Use this line as a base for the props when committing in SVN:

Props kraftbj, bernhard-reiter.

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@kraftbj kraftbj self-assigned this Jan 14, 2026
@kraftbj kraftbj requested a review from priethor January 14, 2026 16:11
@codecov
Copy link

codecov bot commented Jan 14, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 49.73%. Comparing base (7756c10) to head (208e54f).

Additional details and impacted files
@@             Coverage Diff              @@
##              trunk     #355      +/-   ##
============================================
- Coverage     53.67%   49.73%   -3.94%     
  Complexity     4410     4410              
============================================
  Files           298      298              
  Lines         39424    39424              
============================================
- Hits          21161    19609    -1552     
- Misses        18263    19815    +1552     
Flag Coverage Δ
e2e-js 45.02% <ø> (-0.06%) ⬇️
e2e-php 35.80% <ø> (-6.64%) ⬇️
javascript 15.07% <ø> (ø)
phpunit 29.97% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ockham
Copy link
Contributor

ockham commented Jan 22, 2026

See #354 as an example - the codecov/patch check passes (confirming the testable parsing logic has coverage), but codecov/project fails because the CLI orchestration code in bin/ isn't covered.

Seems to be passing now though for that PR?

image

@kraftbj
Copy link
Contributor Author

kraftbj commented Jan 22, 2026

Yeah, the last commit apparently changed the coverage so it wouldn't fail. Here's an example of the run where it did fail https://github.com/WordPress/secure-custom-fields/runs/60370170867

I'm not exactly sure why it differed so much between those two commits.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants