[rspec-users] How to keep mocks consistent?

jshen jaydonnell at yahoo.com
Wed Dec 20 14:53:15 EST 2006

"The isolated unit level testing that you're getting from using mocks
should (MUST) be coupled with  some level of integration testing.
Right now I'm using either rails integration testing and/or selenium."

I have similar concerns and this doesn't quite address them. He asked how to
manage changes that affect mocks that could be in many places. It seems like
something that would be very easy to forget or miss. Also, catching the
errors at the integration level is forcing yourself to test the same
functionality twice. 

I'm just starting with rspec and my standard tests in rails would test
functionality once at the rails unit test level. At the integration level I
would assume the functionality worked and mainly test that the controllers
and views handled different cases (i.e. errors) properly. I know this isn't
ideal, but I'm wondering if the duplication of work, both in testing and in
mock building, is worth the effort on medium sized projects done by small
View this message in context: http://www.nabble.com/How-to-keep-mocks-consistent--tf2842806.html#a7996667
Sent from the rspec-users mailing list archive at Nabble.com.

More information about the rspec-users mailing list