MarkBerlin78 / pymox

Automatically exported from code.google.com/p/pymox
Apache License 2.0
0 stars 0 forks source link

Mox should check that expected calls match with objects API #41

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
If I have a class

class Foo(object):
  def bar(a):
    pass

Then the following should fail
 m_foo = mox.MockObject(Foo)
 m_foo.bar(1, 2)

because the number of arguments doesn't match the acutal implementations 
restrictions.

This will allow tests to fail if the API that they are testing changes from 
beneath them.  

Original issue reported on code.google.com by endob...@google.com on 12 Oct 2011 at 6:16