blob: 6bf8ac7fb6089c181f2a57872f4283cde594b9b5 [file] [log] [blame]
apply plugin: org.robolectric.gradle.RoboJavaModulePlugin
apply plugin: org.robolectric.gradle.DeployedRoboJavaModulePlugin
apply plugin: ShadowsPlugin
shadows {
packageName "org.robolectric.shadows.support.v4"
sdkCheckMode "OFF"
}
configurations {
earlyTestRuntime
}
dependencies {
compileOnly project(":robolectric")
compileOnly project(":shadows:framework")
compileOnly AndroidSdk.MAX_SDK.coordinates
compileOnly "com.android.support:support-annotations:26.0.1"
compileOnly "com.android.support:support-v4:26.0.1"
compileOnly "com.android.support:support-compat:26.0.1"
compileOnly "com.android.support:support-core-ui:26.0.1"
compileOnly "com.android.support:support-core-utils:26.0.1"
compileOnly "com.android.support:support-fragment:26.0.1"
compileOnly "com.android.support:support-media-compat:26.0.1"
testCompileOnly AndroidSdk.MAX_SDK.coordinates
testCompileOnly "com.android.support:support-annotations:26.0.1"
testCompileOnly "com.android.support:support-v4:26.0.1"
testCompileOnly "com.android.support:support-compat:26.0.1"
testCompileOnly "com.android.support:support-core-ui:26.0.1"
testCompileOnly "com.android.support:support-core-utils:26.0.1"
testCompileOnly "com.android.support:support-fragment:26.0.1"
testCompileOnly "com.android.support:support-media-compat:26.0.1"
testImplementation project(":robolectric")
testImplementation "androidx.test.ext:junit:1.1.2-rc03"
testImplementation "junit:junit:4.13.1"
testImplementation "org.hamcrest:hamcrest-junit:2.0.0.0"
testImplementation "com.google.truth:truth:1.0.1"
testImplementation "org.mockito:mockito-core:2.5.4"
earlyTestRuntime "org.hamcrest:hamcrest-junit:2.0.0.0"
testRuntime AndroidSdk.MAX_SDK.coordinates
testRuntime "com.android.support:support-v4:26.0.1"
testRuntime "com.android.support:support-compat:26.0.1"
testRuntime "com.android.support:support-core-ui:26.0.1"
testRuntime "com.android.support:support-core-utils:26.0.1"
testRuntime "com.android.support:support-fragment:26.0.1"
testRuntime "com.android.support:support-media-compat:26.0.1"
}
// hamcrest needs to come before junit on runtime classpath; the gradle IntelliJ plugin
// needs the compileClasspath order patched too (bug?)
sourceSets.test.compileClasspath = configurations.earlyTestRuntime + sourceSets.test.compileClasspath
sourceSets.test.runtimeClasspath = configurations.earlyTestRuntime + sourceSets.test.runtimeClasspath