Python Programming - Testing - Discussion

Discussion Forum : Testing - General Questions (Q.No. 62)
62.
What does the unittest.mock.MagicMock.side_effect attribute validate in Python testing?
Adds a magical side effect to the test
Specifies the return value of a method
Specifies the exception to be raised by a method
Specifies the call count of a method
Answer: Option
Explanation:
The side_effect attribute in Python unittest.mock.MagicMock is used to specify the exception to be raised by a method.
Discussion:
Be the first person to comment on this question !

Post your comments here:

Your comments will be displayed after verification.