test(SemVer): refine tests and remove unnecessary tests which test the behavior of library#1598
Merged
Lee-W merged 1 commit intocommitizen-tools:v4-9-2from Nov 8, 2025
Conversation
bearomorphism
commented
Sep 13, 2025
| assert isinstance(SemVer2("0.0.1"), VersionProtocol) | ||
|
|
||
|
|
||
| def test_semver_sortable(): |
Collaborator
Author
There was a problem hiding this comment.
I'm not sure why we need to test this. The __lt__ operator is defined in packaging library and we are not overriding it.
72bb16e to
4d8f987
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## v4-9-2 #1598 +/- ##
=========================================
Coverage ? 98.32%
=========================================
Files ? 58
Lines ? 2682
Branches ? 0
=========================================
Hits ? 2637
Misses ? 45
Partials ? 0
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
4d8f987 to
8d3387c
Compare
This was referenced Sep 25, 2025
8d3387c to
65ebc5b
Compare
65ebc5b to
56025a2
Compare
bearomorphism
commented
Sep 27, 2025
tests/utils.py
Outdated
Comment on lines
26
to
32
| class VersionSchemeTestArgs(NamedTuple): | ||
| current_version: str | ||
| increment: Increment | None | ||
| prerelease: Prerelease | None | ||
| prerelease_offset: int | ||
| devrelease: int | None | ||
| expected_version: str |
Lee-W
reviewed
Sep 28, 2025
56025a2 to
2aef016
Compare
…e behavior of library, improve readability with NamedTuple
2aef016 to
410d8fb
Compare
Lee-W
approved these changes
Nov 8, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Relate #1631
Description
Checklist
Code Changes
poetry alllocally to ensure this change passes linter check and testsDocumentation Changes
poetry doclocally to ensure the documentation pages renders correctlyExpected Behavior
Steps to Test This Pull Request
Additional Context