Closes issue 14636. mock objects raise exceptions from an iterable side_effect
diff --git a/Doc/library/unittest.mock.rst b/Doc/library/unittest.mock.rst
index ed6775a..12b0275 100644
--- a/Doc/library/unittest.mock.rst
+++ b/Doc/library/unittest.mock.rst
@@ -823,6 +823,20 @@
...
StopIteration
+If any members of the iterable are exceptions they will be raised instead of
+returned::
+
+ >>> iterable = (33, ValueError, 66)
+ >>> m = MagicMock(side_effect=iterable)
+ >>> m()
+ 33
+ >>> m()
+ Traceback (most recent call last):
+ ...
+ ValueError
+ >>> m()
+ 66
+
.. _deleting-attributes: