-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Features assertion pass hook #3479
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
nicoddemus
merged 25 commits into
pytest-dev:master
from
Sup3rGeo:features-assertion-pass-hook
Jun 27, 2019
Merged
Changes from all commits
Commits
Show all changes
25 commits
Select commit
Hold shift + click to select a range
9a89783
Assertion passed hook
52e695b
Removed debug code.
98b212c
Added "experimental" note.
f8c9a7b
Formatting and removed py2 support.
2280f28
Black formatting.
81e3f3c
Black formatting
db50a97
Reverted leak fixture test.
cfbfa53
Using pytester subprocess to avoid keeping references in the HookReco…
4db5488
Now dependent on command line option.
80ac910
Added msg to docstring for cleaning pyc.
7efdd50
Update src/_pytest/assertion/rewrite.py
Sup3rGeo 0fb5241
Reverted changes.
d638da5
Using ini-file option instead of cmd option.
f755ff6
Black formatting.
d91a5d3
Further reverting changes.
9a34d88
Explanation variables only defined if failed or passed with plugins i…
6f851e6
Merge remote-tracking branch 'upstream/master' into features-assertio…
53234bf
Added config back to AssertionWriter and fixed typo in check_if_asser…
6854ff2
Fixed import order pep8.
eb90f3d
Fix default value of 'enable_assertion_pass_hook'
nicoddemus fcbe66f
Restore proper handling of '%' in assertion messages
nicoddemus 3afee36
Improve docs and reference
nicoddemus 8edf68f
Add a trivial note about astor
nicoddemus 629eb3e
Move formatting variables under the "has impls" if
nicoddemus 2ea2221
Cover assertions with messages when enable_assertion_pass_hook is ena…
nicoddemus File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
New `pytest_assertion_pass <https://docs.pytest.org/en/latest/reference.html#_pytest.hookspec.pytest_assertion_pass>`__ | ||
hook, called with context information when an assertion *passes*. | ||
|
||
This hook is still **experimental** so use it with caution. |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
pytest now also depends on the `astor <https://pypi.org/project/astor/>`__ package. |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,6 +13,7 @@ | |
"pluggy>=0.12,<1.0", | ||
"importlib-metadata>=0.12", | ||
"wcwidth", | ||
"astor", | ||
] | ||
|
||
|
||
|
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
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
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.