Pytest-mock

Latest version: v3.14.0

Safety actively analyzes 628924 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 5 of 11

1.12.1

-------------------

* Fix error if ``mocker.patch`` is used in code where the source file
is not available, for example stale ``.pyc`` files (`169`_).

.. _169: https://github.com/pytest-dev/pytest-mock/issues/169#issuecomment-555729265

1.12.0

-------------------

* Now all patch functions also raise a ``ValueError`` when used
as a context-manager. Thanks `AlexGascon`_ for the PR (`168`_).

.. _AlexGascon: https://github.com/AlexGascon
.. _168: https://github.com/pytest-dev/pytest-mock/pull/168

1.11.2

-------------------

* The *pytest introspection follows* message is no longer shown
if there is no pytest introspection (`154`_).
Thanks `The-Compiler`_ for the report.

* ``mocker`` now raises a ``ValueError`` when used as a context-manager.
Thanks `binarymason`_ for the PR (`165`_).

.. _154: https://github.com/pytest-dev/pytest-mock/issues/154
.. _165: https://github.com/pytest-dev/pytest-mock/pull/165
.. _binarymason: https://github.com/binarymason

1.11.1

-------------------

* Fix ``mocker.spy`` on Python 2 when used on non-function objects
which implement ``__call__`` (`157`_). Thanks `pbasista`_ for
the report.

.. _157: https://github.com/pytest-dev/pytest-mock/issues/157
.. _pbasista: https://github.com/pbasista

1.11.0

------

* The object returned by ``mocker.spy`` now also tracks the return value
of the spied method/function.

1.10.4

------

* Fix plugin when 'terminal' plugin is disabled

Page 5 of 11

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.