Replies: 3 comments 6 replies
-
I asked the question in Stackoverflow: https://stackoverflow.com/questions/78274221/use-caplog-in-autouse-fixture-in-pytest |
Beta Was this translation helpful? Give feedback.
0 replies
-
Having the same issue :( I would have thought the caplog wouldn't be cleared until after the test is torn down. |
Beta Was this translation helpful? Give feedback.
0 replies
-
I go it to work: https://stackoverflow.com/a/78276016/24008810
|
Beta Was this translation helpful? Give feedback.
6 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello. I'd like to wrap all my tests with a fixture where the logs are checked for error messages. I tried this:
But caplog.text is always empty. I assume, caplog is cleared after the test and before the fixture actually checks the logs.
How can I make this work?
Beta Was this translation helpful? Give feedback.
All reactions