for anyone else:

http://blog.appmakr.com/android-code-coverage/

On Apr 13, 5:44 pm, Jason Polites <[email protected]> wrote:
> Hi folks,
>
> I'm trying to generate code coverage reports from the junit tests on my
> project, but I keep running into this message:
>
> "nothing to do: no metadata found in any of the data files"
>
> I am running tests using the build script with:
>
> ant -buildfile ...build.xml coverage
>
> It "seems" to be executing correctly.. that is I see all the tests executing
> in the console, and I see the following:
>
> [exec] Generated code coverage data to /data/data/<package path>/files/
> coverage.ec
> [echo] Downloading coverage file into project directory...
> [exec] 570 KB/s (14952 bytes in 0.025s)
> [echo] Extracting coverage report...
> [report] nothing to do: no metadata found in any of the data files
> [echo] Cleaning up temporary files...
> [delete] Deleting directory /<workspace path>/instrumented
> [delete] Deleting: /<workspace path>/coverage.ec
> [echo] Saving the report file in /<workspace path>/coverage/coverage.html
>
> But as you can see, EMMA is reporting "no metadata found in any of the data
> files"
>
> So I don't get an HTML file at all.  There IS a coverage.ec file on the
> device (emulator) but I haven't bothered trying to extract this manually.
>
> I also see the following messages:
>
> Duplicated project name in import. Project android_rules defined first in
> /android/tools/ant/main_rules.xml and again in
> /android-sdk-mac_x86/tools/ant/main_rules.xml
> Trying to override old definition of task aapt
> Trying to override old definition of task aidl
> Trying to override old definition of task renderscript
> Trying to override old definition of task apkbuilder
> Trying to override old definition of task xpath
> Trying to override old definition of task if
> Trying to override old definition of task emmajava
> Trying to override old definition of task emma
>
> Maybe this is related??
>
> Anyone been successful generating coverage reports?
>
> I'm using the latest build tools (Tools rev. 10, Platform Tools rev. 3),
> running on an emulated 2.1-update1 device
>
> Thanks,
>
> Jason.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to