derwiki-adroll / mock

Automatically exported from code.google.com/p/mock
BSD 2-Clause "Simplified" License
0 stars 0 forks source link

If you use a relative path in mock.patch you will get no error, but the patch will not be applied #188

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Use mock.patch with a relative path e.g. contact_form.views.send_mail (which 
is within a django_project folder)
2. No error is presented
3. The patch is not applied to the expected function

What is the expected output? What do you see instead?
I would expected either an error or the patch to work

What version of the product are you using? On what operating system?
mock==1.0.1 on OS X 10.8.2 with Python 2.7.2

Please provide any additional information below.
It was within a Django project and I was mocking a method on a ModelAdmin 
class. Let me know if you need any more info. Thanks!

Original issue reported on code.google.com by davidrey...@googlemail.com on 14 Nov 2012 at 4:32