In my attempt to learn TDD, trying to learn unit testing and using mock with python. Slowly getting the hang of it, but unsure if I\'m doing this correctly. Forewarned: I\
You can create a patched inner function and call it from setUp.
setUp
If your original setUp function is:
def setUp(self): some_work()
Then you can patch it by changing it to:
def setUp(self): @patch(...) def mocked_func(): some_work() mocked_func()