android junit report

The Android JUnit report test runner is a custom instrumentation test runner for Android that creates XML test reports. These reports are in a similar format to those created by the Ant JUnit task's XML formatter, allowing them to be integrated with tools that support that format (e.g. continuous integration servers link Pulse).

Simply configure your Android test project to use this test runner rather than the default, then pull the reports from the Android device for parsing by your builds tool of choice.

quick start

For the impatient, here is an overview of how to integrate the runner with Ant builds. Note all modifications are made to your test project, i.e. the project which implements the JUnit tests:

  • Grab the jar from the downloads page and add it to your libs/ directory.
  • Edit AndroidManifest.xml to set android:name in the <instrumentation> tag to:
  • Edit to add the line:
  • Run your tests as you would normally:
    $ ant debug install test
  • Pull the resulting XML report from the device (from the application under test's internal storage directory):
    $ adb pull /data/data/<main app package>/files/junit-report.xml
  • Integrate the XML with your chosen build tool.

In practice you may want to tweak the report location, add the last pull step to your build, and more. For details, see the documentation page.


Android junit report is available under the Apache License, version 2.0. The license is quite liberal, even for commercial applications. See the LICENSE file for details.

more information

Want to learn more? Check out the following resources:


If you have any thoughts, questions etc about the runner, you can contact me at:

Or you can submit an issue or pull request via GitHub. All feedback is welcome.