I have a problem with using RoboGuice and AndroidMock frameworks in unit testing. I\'ve created a simple project to show my problem. Here I create a mocked instance and register
Unfortunately this is a bug in Android itself. See the bug report here. The VM crashes when it tries to look for annotations on a Proxy, which is what AndroidMock uses when mocking an interface.
The workaround is to create in instance of a class that implements the interface, as you pointed out in your question. You could try making a pure abstract class that implements the interface without implementing any methods, then use AndroidMock to mock that class instead of the interface. This should avoid the creation of a Proxy.