Codemod: remove-assertion-in-pytest-raises#219
Merged
andrecsilva merged 4 commits intomainfrom Jan 22, 2024
Merged
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## main #219 +/- ##
==========================================
- Coverage 96.45% 96.44% -0.01%
==========================================
Files 96 97 +1
Lines 4090 4169 +79
==========================================
+ Hits 3945 4021 +76
- Misses 145 148 +3
|
clavedeluna
reviewed
Jan 19, 2024
clavedeluna
reviewed
Jan 19, 2024
clavedeluna
requested changes
Jan 19, 2024
clavedeluna
reviewed
Jan 22, 2024
| if not self.filter_by_path_includes_or_excludes( | ||
| self.node_position(original_node) | ||
| ): | ||
| return updated_node |
Contributor
There was a problem hiding this comment.
you added a test_exclude_line but still it says not covered.... weird.
Well actually, given this is a leave_with node, it's likely the same issue as the other codemods with this todo # TODO: add filter by include or exclude that works for nodes. So I think you can go ahead and remove the unit test and just add the todo line
clavedeluna
approved these changes
Jan 22, 2024
|
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.



Overview
Adds a codemod that removes assertions from the bottom of
pytest.raisescontext manager.