Now, Eclipse can support Unit Test project for android. By creating a test for each method you declared you can make sure it work correctly. Take note here, there are a different between original Java JUnit Test project and Android JUnit Test project. It is recommend that create a separate new project from the android project you want to testing. It is a slightly different with the Java application practice where it is under a same project but different folder /src and /test. However for android unit test, it is a separate project with its own /src folder. So here is the different:
Java project choose JUnit Test for testing
while Android project choose Android JUnit Test.