Skip to content

Commit

Permalink
Update README and bump version to 0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
nicoddemus committed May 3, 2015
1 parent 7295065 commit 9c8c3d4
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
8 changes: 8 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,14 @@ The supported methods are:
* ``mocker.patch.dict``: see http://www.voidspace.org.uk/python/mock/patch.html#patch-dict.
* ``mocker.stopall()``: stops all active patches at this point.

You can also access ``Mock`` and ``MagicMock`` directly using from ``mocker``
fixture:

.. code-block:: python
def test_feature(mocker):
ret = [mocker.Mock(return_value=True), mocker.Mock(return_value=True)]
mocker.patch('mylib.func', side_effect=ret)
Note
----
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

setup(
name='pytest-mock',
version='0.4.3',
version='0.5.0',
entry_points={
'pytest11': ['pytest_mock = pytest_mock'],
},
Expand Down

0 comments on commit 9c8c3d4

Please sign in to comment.