Files
coco 723ce1af5c a
2026-07-03 15:12:48 +08:00

137 lines
4.7 KiB
Groovy

plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'kotlin-kapt'
id("dagger.hilt.android.plugin")
id("androidx.navigation.safeargs")
id "kotlin-parcelize"
}
android {
compileSdk 33
defaultConfig {
applicationId "com.prmto.mova_movieapp"
minSdk 24
targetSdk 33
versionCode 1
versionName "1.0"
testInstrumentationRunner "com.prmto.mova_movieapp.HiltTestRunner"
Properties properties = new Properties()
properties.load(project.rootProject.file("local.properties").newDataInputStream())
buildConfigField "String", "API_KEY", "\"${properties.getProperty("API_KEY")}\""
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = '1.8'
}
buildFeatures {
viewBinding true
}
}
dependencies {
implementation 'androidx.core:core-ktx:1.9.0'
implementation 'androidx.appcompat:appcompat:1.7.0-alpha01'
implementation 'com.google.android.material:material:1.7.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.4'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.0'
//dagger - hilt
implementation "com.google.dagger:hilt-android:$hilt_version"
kapt "com.google.dagger:hilt-android-compiler:$hilt_version"
kapt "androidx.hilt:hilt-compiler:1.0.0"
// navigation
implementation("androidx.navigation:navigation-fragment-ktx:$nav_version")
implementation("androidx.navigation:navigation-ui-ktx:$nav_version")
// coroutines for getting off the UI thread
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutines"
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutines"
// retrofit for networking
implementation 'com.squareup.retrofit2:retrofit:2.9.0'
implementation 'com.jakewharton.retrofit:retrofit2-kotlin-coroutines-adapter:0.9.2'
implementation 'com.squareup.retrofit2:converter-moshi:2.9.0'
// moshi for parsing the JSON format
implementation "com.squareup.moshi:moshi:$moshi_version"
implementation "com.squareup.moshi:moshi-kotlin:$moshi_version"
kapt "com.squareup.moshi:moshi-kotlin-codegen:$moshi_version"
// logging
implementation 'com.jakewharton.timber:timber:5.0.1'
// DataStore
implementation "androidx.datastore:datastore-preferences:$data_store_version"
//Carousel
implementation 'com.github.sparrow007:carouselrecyclerview:1.2.5'
// Swipe Refresh Layout
implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
//Coil
implementation("io.coil-kt:coil:1.4.0")
implementation("io.coil-kt:coil-svg:1.2.0")
// Shimmer
implementation 'com.facebook.shimmer:shimmer:0.5.0'
//Paging Library
implementation("androidx.paging:paging-runtime:$paging_version")
// Circle Image View
implementation 'de.hdodenhof:circleimageview:3.1.0'
// Local Unit Tests
implementation "androidx.test:core:1.5.0"
testImplementation "junit:junit:4.13.2"
testImplementation "org.hamcrest:hamcrest-all:1.3"
testImplementation "androidx.arch.core:core-testing:2.1.0"
testImplementation "org.robolectric:robolectric:4.5.1"
testImplementation "org.jetbrains.kotlinx:kotlinx-coroutines-test:$coroutines"
testImplementation "com.google.truth:truth:1.1.3"
testImplementation "org.mockito:mockito-core:4.5.1"
testImplementation("io.mockk:mockk:1.13.2")
// Flow Testing
testImplementation 'app.cash.turbine:turbine:0.7.0'
androidTestImplementation "com.google.dagger:hilt-android-testing:$hilt_version"
kaptAndroidTest "com.google.dagger:hilt-android-compiler:$hilt_version"
// Instrumented Unit Tests
androidTestImplementation "junit:junit:4.13.2"
androidTestImplementation "org.jetbrains.kotlinx:kotlinx-coroutines-test:$coroutines"
androidTestImplementation "androidx.arch.core:core-testing:2.1.0"
androidTestImplementation "com.google.truth:truth:1.1.3"
androidTestImplementation 'androidx.test.ext:junit:1.1.4'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.0'
androidTestImplementation "org.mockito:mockito-core:4.5.1"
androidTestImplementation 'org.mockito:mockito-android:4.5.1'
debugImplementation 'androidx.fragment:fragment-testing:1.5.4'
androidTestImplementation "androidx.navigation:navigation-testing:$nav_version"
}