PyTest - Writing Assertions
What is the main purpose of using
pytest.raises in a test?pytest.raises in a test?pytest.raisespytest.raises is used to verify that a certain exception is raised by the code inside its with block.with block correctly states that it checks for a specific exception. Other options describe unrelated behaviors.with block -> Option D15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions