The newest SDK uses emma by putting emma in front of the build:
ant emma debug install
ant emma debug install test
The first is run from your project director, the second the test directory. Doing so will generate the full coverage report.
for more information see this link
The ADT r20-preview solves this issue by giving access to the full classpath of tested projects and their Library Projects:
http://tools.android.com/download/adt-20-preview
This will give you code coverage reports on your library projects, but you will have to do some modifying of the test target of build.xml to attach the source files too.
See this Attach Android library project source code to Emma report (ant, emma) for more information on how to incorporate emma test coverage for your library projects for the time being.
Example-build.xml:
<emma>
<!-- Grantland: Attach Android library project sources to the emma report -->
<report sourcepath="${tested.project.absolute.dir}/${source.dir};${tested.android.library.source.dir}"
verbosity="${verbosity}">
<!-- <report sourcepath="${tested.project.absolute.dir}/${source.dir}"
verbosity="${verbosity}"> -->
<!-- TODO: report.dir or something like should be introduced if necessary -->
<infileset dir=".">
<include name="coverage.ec" />
<include name="coverage.em" />
</infileset>
<!-- TODO: reports in other, indicated by user formats -->
<html outfile="coverage.html" />
</report>
</emma>
ant.properties:
This can be a semicolon delimited list of directories
tested.android.library.source.dir=../library/src;etc