A few days ago I started developing my first native Android App. Finally a green field project! Finally, an opportunity, to do things right! Finally, a project I could develop in a Test-Driven fashion without the weight of any legacy cruft slowing me down! Or so I thought…
With a lot of enthusiasm I bootstrapped a new Maven Project and sure enough there was an Archetype with something called “Instrumentation Tests” included. At that point I had no idea what an “Instrumentation Test” might be, but I thought, if it’s got the word Test in it, it can’t hurt, right?
When I checked the pom.xml file, I noticed there was no JUnit dependency and also the archetype did not generate the usual “src/test” directory sibling of “src/main”. Well, nothing I can’t fix. So I threw in my usual test dependencies and started out writing tests in “src/main”, ignoring the instrumentation project Maven created for now. In retrospect I should have seen the signs on the wall…

