test: generate actions tests for each resource that have actions #545
Merged
test: generate actions tests for each resource that have actions #545
Conversation
Member
jooola
commented
Aug 15, 2025
- Reduce the amount of duplicate tests for the actions calls,
- Ensure consistency across all resources,
- Have few good tests, instead of many with few coverage.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #545 +/- ##
==========================================
+ Coverage 96.14% 96.55% +0.40%
==========================================
Files 64 64
Lines 2928 2928
==========================================
+ Hits 2815 2827 +12
+ Misses 113 101 -12 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
27275d9 to
9b8c612
Compare
Member
Author
|
Coverage has increased, because we now generate tests for the bound models |
Member
Author
|
The trick for this is the parametrized fixture: @pytest.fixture(params=resources_with_actions.keys())https://docs.pytest.org/en/stable/how-to/fixtures.html#fixture-parametrize |
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.