refactor: Pytest based setup for test_plugins#6659
Draft
semohr wants to merge 28 commits into
Draft
Conversation
|
Thank you for the PR! The changelog has not been updated, so here is a friendly reminder to check if you need to add an entry. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #6659 +/- ##
==========================================
- Coverage 72.65% 72.44% -0.21%
==========================================
Files 161 161
Lines 20710 20710
Branches 3276 3276
==========================================
- Hits 15047 15004 -43
- Misses 4934 4980 +46
+ Partials 729 726 -3 🚀 New features to boost your workflow:
|
AlbumArtOperationConfigurationTest -> TestAlbumArtOperationConfiguration
- moved setup into proper pytest fixtures for seperation
EnforceRatioConfigTest -> TestEnforceRatioConfig
fixture into own mixin.
are now provided by the imageResponseMocker. Also fixed indenting of json blocks.
image_response_mocker instead of class inheritance. Aligns more with pytest imo
use the new image_response_mocker and pytest setup
- Renamed image_response_mocker to image_request_mock - Use requests_mock.mocker.Mocker instead of responses.RequestsMock - Renamed function add to get
a729a97 to
88b9ca9
Compare
Member
Contributor
Author
|
It looks like I forgot to rebase it :D Only the last commit is relevant. |
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.
This PR is a minor refactor of
test/test_plugins.pyand replaces the unitest test cases with a pytest setup. Also replaced capture_log with caplog fixture.Needs rebasing after #6658 is merged.
TODOs:
ChangelogNot needed as this is an internal refactor onlyThis is related to the multi-step efforts to improve logging in beets #6553