Some useful material for unit testing on Android:
Samples:
Tutorials:
Robolectric is a unit testing framework for Android. The tests run in JVM so there is no need to instantiate an Android emulator to execute them. This makes running them pretty fast. It still provides context emulation as well as many shadow classes so mocking is usually not needed.
Mockito is a mock/stub library. It can be used with Robolectric but is not necessary.
Selendroid (link), Selenium for Android
Robotium is a set of tools/libraries for UI testing. The principle here is black-box testing of the whole app. These tests require an Android running, meaning that they execute either on a real device or in an emulator. However, the execution is pretty fast even if the tests are being modified because the app does not have to be deployed.
Espresso is Google's UI testing framework.
Testing on multiple devices - link
BDD is a design philosophy. It is an evolution of Test-Driven Development (TDD) and acceptance testing, and merges the two concepts together.
Hamcrest matchers contain lots of useful matchers for assertions and comparison of elements during tests. Useful for both unit and UI tests.