Android:Resolved versions for app (26.1.0) and test app (27.1.1)

错误如下:

Error:Execution failed for task ':app:preDebugAndroidTestBuild'.
> Conflict with dependency 'com.android.support:support-annotations' in project ':app'. Resolved versions for app (26.1.0) and test app (27.1.1) differ. See https://d.android.com/r/tools/test-apk-dependency-conflicts.html for details.

解决方法:

找到app目录下build.gradle.

androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'

注释掉就可以了。

猜你喜欢

转载自blog.csdn.net/qq_30180491/article/details/81116474