Un post interessante a proposito dell'uso dei Mock objects per lo Unit testing dell'accesso ai dati...
More than a year ago I wrote about the problems in database testing.
I also stated that I feel it's totally wrong to
run your unit tests against a live test database, but instead you should be
using mock objects to save you from all the trouble. Boy have things changed since then. I take back what I said. For a long time now I've been doing DB testing without mock objects, because I believe that's currently the best way to make sure you test data access logic and integration with
the database procedures and views.
With those - there's no reason for you not to do
it.
Funny how things change overtime. Like any other thing, but usually more, software development is one of those things that looking back 6 months from now I'll always say to myself "Gosh! if I knew then what I
now!"..
Source: I changed my mind - Mock objects are wrong for database unit testing