A short little plugin to find where a mock was called!
This library is setup as a pytest plugin, so if you're using pytest you can just add the mock_where fixture in your tests. If you'd like to always have it enabled...
from mock_call_where.override import AdvancedCall AdvancedCall.apply() ... # The plugin is enabled now AdvancedCall.unapply()
This project uses pre-commit, please make sure to install it before making any changes:
pip install pre-commit cd mock-call-where pre-commit install
It is a good idea to update the hooks to the latest version:
pre-commit autoupdate
Don't forget to tell your contributors to also install and use pre-commit.
This project has been set up using PyScaffold 4.5. For details and usage information on PyScaffold see https://pyscaffold.org/.