2026-09-26 22:45:38 +03:00
|
|
|
plugins {
|
|
|
|
|
id("com.android.application")
|
|
|
|
|
id("kotlin-android")
|
|
|
|
|
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
|
|
|
|
|
id("dev.flutter.flutter-gradle-plugin")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
android {
|
|
|
|
|
namespace = "com.example.smol_mail"
|
|
|
|
|
compileSdk = flutter.compileSdkVersion
|
|
|
|
|
ndkVersion = "27.0.12077973"
|
|
|
|
|
|
|
|
|
|
compileOptions {
|
|
|
|
|
sourceCompatibility = JavaVersion.VERSION_11
|
|
|
|
|
targetCompatibility = JavaVersion.VERSION_11
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
kotlinOptions {
|
|
|
|
|
jvmTarget = JavaVersion.VERSION_11.toString()
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
defaultConfig {
|
|
|
|
|
applicationId = "com.app.smol_mail"
|
|
|
|
|
minSdk = flutter.minSdkVersion
|
|
|
|
|
targetSdk = flutter.targetSdkVersion
|
|
|
|
|
versionCode = flutter.versionCode
|
|
|
|
|
versionName = flutter.versionName
|
2026-09-28 23:49:39 +03:00
|
|
|
// The Android Test Orchestrator (with clearPackageData) wipes the
|
|
|
|
|
// integration flavor's app data between test runs, and the flavor
|
|
|
|
|
// installs it beside — never over — the real app, so every patrol run
|
|
|
|
|
// starts at onboarding with a fresh identity.
|
|
|
|
|
testInstrumentationRunner = "pl.leancode.patrol.PatrolJUnitRunner"
|
|
|
|
|
testInstrumentationRunnerArguments["clearPackageData"] = "true"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
testOptions {
|
|
|
|
|
execution = "ANDROIDX_TEST_ORCHESTRATOR"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
flavorDimensions += "test"
|
|
|
|
|
productFlavors {
|
|
|
|
|
create("integration") {
|
|
|
|
|
dimension = "test"
|
|
|
|
|
applicationIdSuffix = ".integration"
|
|
|
|
|
versionNameSuffix = "-integration"
|
|
|
|
|
}
|
2026-09-26 22:45:38 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
buildTypes {
|
|
|
|
|
release {
|
|
|
|
|
// Signing with the debug keys for now, so `flutter run --release` works.
|
|
|
|
|
signingConfig = signingConfigs.getByName("debug")
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
flutter {
|
|
|
|
|
source = "../.."
|
|
|
|
|
}
|
2026-09-28 23:49:39 +03:00
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
|
// The orchestrator referenced by testOptions.execution above. The patrol
|
|
|
|
|
// native library itself comes from the patrol pub package's android
|
|
|
|
|
// module (a plugin subproject), not from a Maven artifact.
|
|
|
|
|
androidTestUtil("androidx.test:orchestrator:1.5.1")
|
|
|
|
|
}
|