Android Espresso Issue - Dependency conflict

前端 未结 8 1881
Happy的楠姐
Happy的楠姐 2021-02-12 16:34

I\'m trying to integrate espresso into my application for ui testing. Here are my dependencies in Gradle

dependencies {
    compile fileTree(dir: \'libs\', inclu         


        
相关标签:
8条回答
  • 2021-02-12 17:25

    The problem is in this file: android-sdk\extras\android\m2repository\com\android\support\test\runner\0.3\runner-0.3.pom

    here:

    <dependency>
          <groupId>com.android.support</groupId>
          <artifactId>support-annotations</artifactId>
          <version>22.2.0</version>
          <scope>compile</scope>
    </dependency>
    

    if you set 22.2.1 instead 22.2.0 it will work

    0 讨论(0)
  • 2021-02-12 17:26

    So after a lot of digging around, I found I needed to change the dependency for the support annotations.

    So I needed to change compile 'com.android.support:support-annotations:22.2.0' to androidTestCompile 'com.android.support:support-annotations:22.+'

    0 讨论(0)
提交回复
热议问题