I personally am not a fan of too many abstractions.
If the only reason for abstraction is testing, then mocking an interface seems like a more valid choice to me.
If the only reason for abstraction is testing, then mocking an interface seems like a more valid choice to me.
Then you're likely in the wrong business, since most of what programming is is dealing with the various facets of one abstraction or another.
I just prefer to abstract when I have more reasons that just testing. That can be done using mocking techniques.
https://docs.spring.io/spring/docs/2.5.x/javadoc-api/org/spr...