Compatibility of terminal summary hook with pytest<4.2#5
Merged
bors[bot] merged 2 commits intoaragilar:masterfrom May 27, 2020
Merged
Conversation
Pytest 4.2 introduced the config argument to pytest_terminal_summary, which is not backwards compatible
Codecov Report
@@ Coverage Diff @@
## master #5 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 2 2
Lines 113 116 +3
=========================================
+ Hits 113 116 +3
Continue to review full report at Codecov.
|
Contributor
Author
Owner
|
Oops, sorry I missed this, I'll try to get to this later today and release it on PyPI. |
Owner
|
bors r+ |
Contributor
|
Build succeeded:
|
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.
Hello!
Pytest 4.2 introduced the
configargument topytest_terminal_summary, which is not backwards compatible.I added a flag that is initialized when the hook
pytest_configureis called, which is then used in thepytest_terminal_summaryinstead of the previousconfigargument. I tried with versions 3.10.1 and 5.4.2 on a homegrown test and it works. I am unfamiliar with tox, but I think it would be best if several versions of pytest were tested.Fixes #3
By the way, the version on pypi is out of date with respect to bugfixes on
min_sizefor mpi tests.Cheers!