Joined March 2012
·

Paweł Pierzchała

dev
·
Kraków
·
·
·

Posted to Safe stubbing with bogus over 1 year ago

Do you mean spy? If so, Bogus supports spies as well, actually that is the recommended way of testing with it.

In spy mock objectes are created as doubles of given class, which breaks to rule mock roles not objects. In bogus fakes are identified by a symbol, which by convention points to the camelized class, but it can be configured to any other class or even a 'lowest common interface'.

Another feature that differenties Bogus from rspec-fire or spy are contract test. They make sure that objects tested in isolation can be integrated with each other without any integration tests. However, it is still an experimental part.

Achievements
135 Karma
2,812 Total ProTip Views