mock DB, was: Spring / IoC, unit-testing
Thomas L Roche <tlroche-r/[email protected]>
| Newsgroups | gmane.org.user-groups.trijug.juglist |
|---|---|
| Message-ID | <OF22373AD9.41E05572-ON872570E5.006ECBBC-852570E5.006F307B@us.ibm.com> |
Phillip Rhodes 12/28/2005 12:37:42 PM: > working out how to unit-test DAOs which encapsulate Hibernate > operations is still kinda tricky for the same reason that all DB > related unit-testing is. Mock Object still apply I suppose, but it > seems like a lot of hassleto write mocks to stand in for the actual > database. So why do it? Why not just have a test DB? Unless you're really paranoid/careless you can have a test DB on the same server as production, so setup is not much work (though keeping schema in sync might be). FWIW, Tom "motley.crüe.foe" Roche