我正在尝试向Intellij中的应用程序添加一些单元测试。由于我的应用程序使用Google Maps,因此我的Build Target设置为“Google API(2.1)”。我的项目编译和运行良好,但是当我试图创建一个使用任何的IntelliJ的内置工具或命令行工具的测试中,我得到这个错误:尝试在使用Google API时在Android中创建测试时出错
Found main project package: com.project
Found main project activity: .mainActivity
Error: Unable to resolve main project target 'Google Inc.\:Google APIs\:7'. You may want to install the platform in your SDK.
任何想法?
嗨,面临同样的问题:当为简单的android项目创建junit时 - 这个想法说的是相同的(仅适用于8 api)。如果命令行工具修复了问题并恢复了编辑的project.properties - 为什么你应该手动编辑它们? – yetanothercoder 2012-05-19 12:57:11