title: Android - NoClassDefFoundError on Added API Class
body: <p>I am currently testing the Android API and its database classes. To do this, I created an application and test that calls up these database classes (especially SQLiteDatabase). The test and application run fine normally, but to get coverage, I decided to go in and add a "cov" class to the <code>android.database</code> package in the Android API that would collect coverage from modified versions of the android.database and android.database.sqlite classes. I imported "android.database.cov" into my class, and the test itself runs fine, but when I get to using cov</p>
  
  <pre><code>System.out.println(cov.printArray());
  cov.reset();
  </code></pre>
  
  <p>I get the following failure trace on my JUnit test:</p>
  
  <pre><code>java.lang.NoClassDefFoundError: android.database.cov
  at com.example.sql2.test.SQLSuiteVer2.testSuite(SQLSuiteVer2.java:91)
  at java.lang.reflect.Method.invokeNative(Native Method)
  at android.test.InstrumentationTestCase.runMethod(InstrumentationTestCase.java:214)
  at android.test.InstrumentationTestCase.runTest(InstrumentationTestCase.java:199)
  at android.test.ActivityInstrumentationTestCase2.runTest(ActivityInstrumentationTestCase2.java:192)
  at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:190)
  at android.test.AndroidTestRunner.runTest(AndroidTestRunner.java:175)
  at android.test.InstrumentationTestRunner.onStart(InstrumentationTestRunner.java:555)
  at android.app.Instrumentation$InstrumentationThread.run(Instrumentation.java:1584)
  </code></pre>
  
  <p>Does anyone know what this is happening? I'm assuming we missed something in creating our android.jar file, or some initialization for the "cov" class.</p>
  
  <p>Thanks. </p>