升级到 android sdk tools v14 并将现有项目更新到最后一个项目结构后,ant test
失败并显示错误消息:
test:
[echo] Running tests ...
[exec] Syntax error: Bad substitution`
的输出ant -v test
[echo] Running tests ...
[exec] Current OS is Mac OS X
[exec] Executing '/opt/local/share/java/android-sdk-mac_x86/platform-tools/adb' with arguments:
[exec] 'shell'
[exec] 'am'
[exec] 'instrument'
[exec] '-w'
[exec] '-e'
[exec] 'coverage'
[exec] 'false'
[exec] 'xxx.xxx/xxx.xxx'
[exec]
[exec] The ' characters around the executable and arguments are
[exec] not part of the command.
但是直接执行命令adb shell am instrument
就可以了。我的环境是 Mac 上的 Apache Ant(TM) 版本 1.8.2。请帮忙。