Skip to content

chore: improve test coverage - #3828

Merged
frostming merged 2 commits into
mainfrom
chore/increase-coverage
Jul 30, 2026
Merged

chore: improve test coverage#3828
frostming merged 2 commits into
mainfrom
chore/increase-coverage

Conversation

@frostming

Copy link
Copy Markdown
Collaborator

Signed-off-by: Frost Ming me@frostming.com

Pull Request Checklist

  • A news fragment is added in news/ describing what is new.
  • Test cases added for changed code.

Describe what you have changed in this PR.

Signed-off-by: Frost Ming <me@frostming.com>

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 699371dcb1

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread pyproject.toml Outdated
Comment on lines +195 to +197
"*/pdm/cli/commands/search.py",
"*/pdm/pep582/sitecustomize.py",
"*/pdm/models/search.py",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Keep the search modules in coverage accounting

Removing both search modules from coverage, while also marking PyPIRepository.search() as uncovered, causes the 84% coverage gate to ignore this still-callable code entirely. In particular, tests/cli/test_search.py already exercises pdm.cli.commands.search, but those tests will no longer contribute coverage or detect a future loss of execution; regressions in SearchResultParser and repository search can similarly accumulate without affecting CI. Keep these modules measured and add focused tests for the remaining paths instead of excluding them wholesale.

Useful? React with 👍 / 👎.

@codecov

codecov Bot commented Jul 30, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 88.16%. Comparing base (8ddfa3a) to head (90bb028).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3828      +/-   ##
==========================================
+ Coverage   86.43%   88.16%   +1.72%     
==========================================
  Files         121      121              
  Lines       13232    13221      -11     
  Branches     2247     2246       -1     
==========================================
+ Hits        11437    11656     +219     
+ Misses       1182      982     -200     
+ Partials      613      583      -30     
Flag Coverage Δ
unittests 88.04% <ø> (+1.72%) ⬆️

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.

…pository

Signed-off-by: Frost Ming <me@frostming.com>
@frostming
frostming merged commit b3cb02e into main Jul 30, 2026
25 checks passed
@frostming
frostming deleted the chore/increase-coverage branch July 30, 2026 02:46
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