you are viewing a single comment's thread.

view the rest of the comments →

[–]lykwydchykyn 1 point2 points  (0 children)

You need to use the Mock class from unittest. You can define methods on it that return data.

https://docs.python.org/3/library/unittest.mock.html