Assertion rewrites not applied when running pytest
within an embedded Python environment
#12454
-
I'm trying to use def test_failing():
assert False Yet if I change To address #12453, I've been trying to figure out how to use |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
I'm confused why you think this is related to assertion rewriting. An It sounds like something is broken in your Python environment. Possibly you're using |
Beta Was this translation helpful? Give feedback.
I'm confused why you think this is related to assertion rewriting. An
assert False
should cause anAssertionError
in Python - rewritten or not, and even outside of pytest. All rewriting does is showing additional context when the assertion fails.It sounds like something is broken in your Python environment. Possibly you're using
PYTHONOPTIMIZE
/-O
?