发电code覆盖率报告为Android测试项目 [英] generating code coverage report for android test project
问题描述
我想获得一个覆盖率报告我的Android JUnit测试项目并按照<一href="http://blog.rabidgremlin.com/2010/11/19/android-tips-generating-a-coverage-report-for-your-unit-tests/"相对=nofollow>这个指南这样做
i am trying to get a coverage report for my android junit test project and following this guide to do so
android update test-project -m <path to app project> -p <path to test project>
工作的罚款。它产生一个build.xml和更新project.properties, local.properties和proguard.cfg。
worked fine. it generated a build.xml and updated project.properties, local.properties and proguard.cfg.
但是当我改变目录测试项目的目录,然后输入命令
but when I change directory to test project directory and enter command
ant coverage
它给了我这个错误。
it gives me this error.
BUILD FAILED
Target "coverage" does not exist in the project "My Project Test".
Total time: 0 seconds
我使用Windows XP。
I am using windows xp.
推荐答案
哪个SDK工具版本您使用的?如果是14或更高版本,你需要使用蚂蚁艾玛调试安装测试
而不是蚂蚁报道
Which SDK Tools version are you using? If it is 14 or later, you need to use ant emma debug install test
instead of ant coverage
这篇关于发电code覆盖率报告为Android测试项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!