Start on Robolectric integration test

I've just created this pull request as a basis for discussion on the mailing list. You don't have to merge it.