diff options
author | Allan Wang <me@allanwang.ca> | 2020-06-27 23:10:57 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-27 23:10:57 -0700 |
commit | 813f3867839d015c123625eb0a4586e79e210200 (patch) | |
tree | 322e6852a59ef773577a19ee5dc01f2cd8f1ac23 /sample/build.gradle | |
parent | 9aff74e3f14cc257e53dc2b8a18658b91e0a2802 (diff) | |
parent | 2368c3fe526b99427560332e2ec3ecec57870294 (diff) | |
download | kau-813f3867839d015c123625eb0a4586e79e210200.tar.gz kau-813f3867839d015c123625eb0a4586e79e210200.tar.bz2 kau-813f3867839d015c123625eb0a4586e79e210200.zip |
Merge pull request #254 from AllanWang/hilt
Diffstat (limited to 'sample/build.gradle')
-rw-r--r-- | sample/build.gradle | 39 |
1 files changed, 18 insertions, 21 deletions
diff --git a/sample/build.gradle b/sample/build.gradle index 96ed78f..d620c2a 100644 --- a/sample/build.gradle +++ b/sample/build.gradle @@ -2,8 +2,10 @@ import kau.Dependencies apply plugin: 'com.android.application' apply plugin: 'kotlin-android' +apply plugin: 'kotlin-kapt' apply plugin: 'kotlin-android-extensions' apply plugin: 'com.github.triplet.play' +apply plugin: 'dagger.hilt.android.plugin' play { serviceAccountCredentials = file('../files/gplay-keys.json') @@ -99,25 +101,15 @@ android { main.res.srcDirs += 'src/main/res-public' } - testOptions.unitTests { - // Don't throw runtime exceptions for android calls that are not mocked - returnDefaultValues = true + testOptions { + unitTests { + // Don't throw runtime exceptions for android calls that are not mocked + returnDefaultValues = true - // Always show the result of every unit test, even if it passes. - all { - testLogging { - events 'passed', 'skipped', 'failed', 'standardOut', 'standardError' - } - } - } - - // See https://github.com/facebook/flipper/issues/146 - configurations.all { - resolutionStrategy.eachDependency { DependencyResolveDetails details -> - def requested = details.requested - if (requested.group == "com.android.support") { - if (!requested.name.startsWith("multidex")) { - details.useVersion "26.+" + // Always show the result of every unit test, even if it passes. + all { + testLogging { + events 'skipped', 'failed', 'standardOut', 'standardError' } } } @@ -135,12 +127,16 @@ dependencies { implementation project(':searchview') implementation project(':mediapicker') + implementation Dependencies.hilt + kapt Dependencies.hiltCompiler + implementation Dependencies.materialDialog("input") - implementation Dependencies.koin testImplementation Dependencies.kotlinTest testImplementation Dependencies.junit - testImplementation Dependencies.koinTest + testImplementation Dependencies.hiltTest + kaptTest Dependencies.hiltCompiler + androidTestImplementation Dependencies.kotlinTest androidTestImplementation Dependencies.espresso @@ -148,5 +144,6 @@ dependencies { androidTestImplementation Dependencies.espresso("contrib") androidTestImplementation Dependencies.testRules androidTestImplementation Dependencies.testRunner - androidTestImplementation Dependencies.koinTest + testImplementation Dependencies.hiltTest + kaptTest Dependencies.hiltCompiler } |