Relative Content

Tag Archive for pythonunit-testingtkintermockingpatch

Python unittest: Mock function used as parameter inside mocked function

I am trying to mock a function call which is inside the actual function I am trying to mock. I want to check that an algorithm is correct, but I have a draw_data() inside the function, which is recieved as a parameter. I don’t want to use that in the unittests, however. My actual program is a algorithm visualiser, so the draw_data() is supposed to display it on a gui.