I'm trying to use the Spoon plugin for my Instrumentation Tests, but I am unable to proceed with a Gradle error unable to resolve dependency Failed to resolve: com.squareup.spoon:spoon-client:2.0.0-SNAPSHOT
.
I used this guide: https://github.com/jaredsburrows/gradle-spoon-plugin/blob/master/README.md
My actual top build.gradle file
buildscript {
repositories {
mavenCentral()
maven {
url "https://oss.sonatype.org/content/repositories/snapshots"
}
}
dependencies {
classpath 'com.android.tools.build:gradle:7.1.3'
classpath 'com.jaredsburrows:gradle-spoon-plugin:1.6.0-SNAPSHOT'
}
}
repositories {
// For Spoon snapshot, until 2.0.0 is released
maven { url 'https://oss.sonatype.org/content/repositories/snapshots' }
}
My module build.gradle file:
apply plugin: 'com.jaredsburrows.spoon'
// other necessary stuff here
dependencies {
androidTestImplementation 'com.squareup.spoon:spoon-client:2.0.0-SNAPSHOT'
}
Is my setup incorrect? or is there something I missed? Thanks in advance for the help!
This is already resolved. The maven repository should be placed inside my build.gradle's allprojects
section.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.