Skip to content

SG-43838 [Coverage test] Uncovered function to validate advisory-only threshold#1110

Closed
stevelittlefish wants to merge 2 commits into
sg-43838/improve-codecov-configfrom
sg-43838/test-coverage-threshold
Closed

SG-43838 [Coverage test] Uncovered function to validate advisory-only threshold#1110
stevelittlefish wants to merge 2 commits into
sg-43838/improve-codecov-configfrom
sg-43838/test-coverage-threshold

Conversation

@stevelittlefish

@stevelittlefish stevelittlefish commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Purpose

This PR exists purely to validate that the Codecov configuration changes in #1109 work as intended.

It adds format_version_range() to tank/util/version.py — a plausible but deliberately untested utility function. No tests cover it, so Codecov will report 0% patch coverage for the changed lines.

What we expect to see

Without #1109 With #1109
CI goes red, patch coverage fails CI stays green, check is advisory only
Codecov blocks merge Codecov reports the miss but does not block

If CI is green on this PR despite the uncovered lines, the threshold config is working correctly.

What to check after CI runs

  • GitHub status checks are green (not red) on this PR
  • Codecov still posts a PR comment showing the coverage miss
  • The Codecov check is marked as informational, not a failure

Jira: SG-43838

🤖 Generated with Claude Code

This function is intentionally not covered by tests. It exists solely
to verify that the codecov.yml changes in the parent branch cause
Codecov to report the miss as advisory-only rather than failing CI.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@codecov

codecov Bot commented Jun 24, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 85.71429% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 79.46%. Comparing base (67aa36f) to head (dc1f3cf).

Files with missing lines Patch % Lines
python/tank/util/version.py 85.71% 1 Missing ⚠️
Additional details and impacted files
@@                         Coverage Diff                         @@
##           sg-43838/improve-codecov-config    #1110      +/-   ##
===================================================================
- Coverage                            79.46%   79.46%   -0.01%     
===================================================================
  Files                                  206      206              
  Lines                                21007    21014       +7     
===================================================================
+ Hits                                 16694    16698       +4     
- Misses                                4313     4316       +3     
Flag Coverage Δ
Linux 78.93% <85.71%> (+<0.01%) ⬆️
Python-3.10 79.28% <85.71%> (+<0.01%) ⬆️
Python-3.11 79.18% <85.71%> (+<0.01%) ⬆️
Python-3.13 79.18% <85.71%> (+<0.01%) ⬆️
Python-3.9 79.25% <85.71%> (-0.01%) ⬇️
Windows 78.96% <85.71%> (-0.01%) ⬇️
macOS 78.94% <85.71%> (+<0.01%) ⬆️

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

☔ View full report in Codecov by Harness.
📢 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.

Adds str() coercion to format_version_range (7 executable lines) and
tests for the open-ended and bounded-range paths, leaving only the
ValueError branch uncovered. Expected patch coverage: 6/7 = 85.7%.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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.

1 participant