Pytest-mock

Latest version: v3.12.0

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

Scan your dependencies

Page 1 of 11

3.12.0

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

* Added support for Python 3.12.
* Dropped support for EOL Python 3.7.
* ``mocker.resetall()`` now also resets mocks created by ``mocker.create_autospec`` (`390`_).

.. _390: https://github.com/pytest-dev/pytest-mock/pull/390

3.11.1

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

(This release source code is identical to ``3.11.0`` except a small internal fix to deployment/CI)

* Fixed introspection for failed ``assert_has_calls`` (`365`_).

* Updated type annotations for ``mocker.patch`` and ``mocker.spy`` (`364`_).

.. _365: https://github.com/pytest-dev/pytest-mock/pull/365
.. _364: https://github.com/pytest-dev/pytest-mock/pull/364

3.11.0

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

* Fixed introspection for failed ``assert_has_calls`` (`365`_).

* Updated type annotations for ``mocker.patch`` and ``mocker.spy`` (`364`_).

.. _365: https://github.com/pytest-dev/pytest-mock/pull/365
.. _364: https://github.com/pytest-dev/pytest-mock/pull/364

3.10.0

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

* Added new ``mocker.stop(m)`` method to stop specific ``mocker.patch`` or ``mocker.spy`` calls (`319`_).

.. _319: https://github.com/pytest-dev/pytest-mock/pull/319

3.9.0

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

* Expose ``NonCallableMagicMock`` via the ``mocker`` fixture (`318`_).

.. _318: https://github.com/pytest-dev/pytest-mock/pull/318

3.8.2

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

- Fixed ``AsyncMock`` support for Python 3.7+ in ``mocker.async_stub`` (`302`_).

.. _302: https://github.com/pytest-dev/pytest-mock/pull/302

Page 1 of 11

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.