So I am trying to use unittest.mock to mock some of my methods in my unit tests. I do:
from unittest.mock import MagicMock
f = open("data/static/mock_ffprobe_response")
subprocess.check_output = MagicMock(return_value=f.read())
f.close()
But I am getting:
ImportError: No module named mock
I tried:
pip install mock
It's still not working.