Using EasyMock
EasyMock provides Mock Objects for interfaces in tests by generating them on the fly using Java's proxy mechanism. That's just what we need here. Several versions are available. We are using version 2.2 which relies on Java 5. Here is how we can test JavaStorer using that version of EasyMock:
Labels