Skip to content

Commit 0711721

Browse files
committed
add Kotlin dependencies
1 parent c4c8ead commit 0711721

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

ui/espresso/RecyclerViewSample/app/build.gradle

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@
1616

1717
apply plugin: 'com.android.application'
1818

19+
apply plugin: 'kotlin-android'
20+
21+
apply plugin: 'kotlin-android-extensions'
22+
1923
android {
2024
compileSdkVersion 30
2125
buildToolsVersion rootProject.buildToolsVersion
@@ -40,15 +44,24 @@ android {
4044
}
4145
}
4246

47+
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all {
48+
kotlinOptions {
49+
jvmTarget = "1.8"
50+
}
51+
}
52+
4353
dependencies {
4454
// App dependencies
4555
implementation 'androidx.annotation:annotation:' + rootProject.androidxAnnotationVersion;
4656
implementation 'androidx.recyclerview:recyclerview:' + rootProject.androidxRecyclerVersion;
4757
implementation 'androidx.multidex:multidex:2.0.1'
4858

4959
// Testing-only dependencies
60+
androidTestImplementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlinVersion";
5061
androidTestImplementation 'androidx.test:core:' + rootProject.coreVersion;
62+
androidTestImplementation 'androidx.test:core-ktx:' + rootProject.coreVersion;
5163
androidTestImplementation 'androidx.test.ext:junit:' + rootProject.extJUnitVersion;
64+
androidTestImplementation 'androidx.test.ext:junit-ktx:' + rootProject.extJUnitVersion;
5265
androidTestImplementation 'androidx.test:runner:' + rootProject.runnerVersion;
5366
androidTestImplementation 'androidx.test.espresso:espresso-core:' + rootProject.espressoVersion;
5467
androidTestImplementation 'androidx.test.espresso:espresso-contrib:' + rootProject.espressoVersion;

ui/espresso/RecyclerViewSample/build.gradle

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
// Top-level build file where you can add configuration options common to all sub-projects/modules.
1818

1919
buildscript {
20+
ext.kotlinVersion = "1.6.10"
2021
ext.agpVersion = "7.3.0-alpha07"
2122
repositories {
2223
// Insert local test repo here
@@ -25,6 +26,7 @@ buildscript {
2526
}
2627
dependencies {
2728
classpath "com.android.tools.build:gradle:$agpVersion"
29+
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
2830

2931
// NOTE: Do not place your application dependencies here; they belong
3032
// in the individual module build.gradle files

0 commit comments

Comments
 (0)