Hi Sean. You're using the mock_method() function correctly...
class Foo:
def greeting(self):
return 'hi'
f = Foo()
print f.greeting()
mocking.mock_method(Foo, 'greeting', mocking.return_value('bye'))
print f.greeting()
===
Damian,
I am attempting to write a test using test.mocking.mock_method, but I do
not understand how to use it correctly. Could you give me pointers on the
following smallest (non-)working test case.
import stem
from stem.control import Controller
import test.mocking as mocking
socket = stem.soc