Conflict with dependency 'com.android.support:support-annotations'. Resolved versions for app (23.1.0) and test app (23.0.1) differ

后端 未结 9 1233
臣服心动
臣服心动 2020-11-28 21:38

When building I get the following error:

Conflict with dependency \'com.android.support:support-annotations\'. Resolved versions for app (23.1.0) and test a         


        
9条回答
  •  野趣味
    野趣味 (楼主)
    2020-11-28 22:05

    In my case, I added below code in dependencies of app level build.gradle

    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
        exclude group: 'com.android.support', module: 'support-annotations'
    })
    

    After that, I clean the project and rebuild.My problem solved.

提交回复
热议问题