Fernando P. wrote:
I was refactoring my model specs so that they don’t hit the database,
but how to handle a custom find that uses :joins or :include with some
important :conditions? I can’t see a way to not hit the database.
What’s wrong with hitting the database?
When high-end consultants like Mike Feathers tell you not to hit the
what they are really saying is that programmers using big iron languages
C++ or Java should start decoupling by any means necessary. It’s just a
At the other extreme, systems like Rails and its test fixtures have
how you can leverage the database for a pool of stub objects. It doesn’t
bad design, or slow tests down.