Skip to content

Commit 5d5fb6c

Browse files
committed
Add google() repo to missing gradle script files
1 parent 581e92f commit 5d5fb6c

File tree

2 files changed

+18
-16
lines changed

2 files changed

+18
-16
lines changed

instrumentation-runner/build.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import org.junit.platform.console.options.Details
33

44
buildscript {
55
repositories {
6+
google()
67
jcenter()
78
}
89

sample/build.gradle

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
buildscript {
22
repositories {
3+
google()
34
jcenter()
45
}
56

@@ -24,20 +25,22 @@ android {
2425
versionName "1.0"
2526

2627
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
27-
testInstrumentationRunnerArgument "runnerBuilder", "de.mannodermaus.junit5.AndroidJUnit5Builder"
2828
}
2929

30-
flavorDimensions "kind"
31-
productFlavors {
32-
experimental {
33-
dimension "kind"
34-
minSdkVersion 26
35-
}
36-
37-
normal {
38-
dimension "kind"
39-
}
40-
}
30+
// Since the minSdkVersion requirement for JUnit 5 Instrumentation Tests is quite high,
31+
// we introduce a product flavor that uses an elevated version other than the application's default.
32+
// With this, we are able to write JUnit 5
33+
// flavorDimensions "kind"
34+
// productFlavors {
35+
// experimental {
36+
// dimension "kind"
37+
// minSdkVersion 26
38+
// }
39+
//
40+
// normal {
41+
// dimension "kind"
42+
// }
43+
// }
4144

4245
// Add Kotlin source directory to all source sets
4346
sourceSets.each {
@@ -71,8 +74,6 @@ dependencies {
7174
androidTestImplementation "junit:junit:$JUNIT4_VERSION"
7275
androidTestImplementation "com.android.support.test:runner:$SUPPORT_TEST_LIBRARY_VERSION"
7376

74-
androidTestRuntimeOnly project(":instrumentation-runner")
75-
androidTestExperimentalImplementation junit5.unitTests()
76-
androidTestExperimentalImplementation junit5.parameterized()
77-
androidTestExperimentalImplementation project(":instrumentation")
77+
// androidTestExperimentalImplementation junit5.unitTests()
78+
// androidTestExperimentalImplementation junit5.instrumentationTests()
7879
}

0 commit comments

Comments
 (0)