About Andrew Glover
I recently found myself writing some code to integrate two disparate platforms. One of these systems is Java based and the other, while not written in Java, offers a Java API. I’ll call these systems Foo and Bar, respectively.
It became obvious before I had written a line of code, however, that testing the eventual adapter would require I explicitly mock the later system’s API (i.e. Foo’s) as all I had to go with was a jar file whose classes and methods made it clear they communicated with a live instance.
I spent a few cycles to see what’s new in the world of Java mocking and I was pleased to see that my old friend Mockito is still active and is indeed, still an excellent tool for general purpose mocking. For the uninitiated, Mockito is Java based mocking framework that:
…tastes really good. It lets you write beautiful tests with [a] clean & simple API. Mockito doesn’t give you hangover because the tests are very readable and they produce clean verification errors.
Source : http://www.javacodegeeks.com/2013/08/imbibing-the-fluency-of-mockito.html