diff --git a/android/build.gradle.kts b/android/build.gradle.kts new file mode 100644 index 0000000..d74e97c --- /dev/null +++ b/android/build.gradle.kts @@ -0,0 +1,76 @@ +group = "xyz.nuark.liblinphone_flutter" +version = "1.0-SNAPSHOT" + +buildscript { + val kotlinVersion = "2.2.20" + repositories { + google() + mavenCentral() + } + + dependencies { + classpath("com.android.tools.build:gradle:8.11.1") + classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion") + } +} + +allprojects { + repositories { + google() + mavenCentral() + } +} + +plugins { + id("com.android.library") + id("kotlin-android") +} + +android { + namespace = "xyz.nuark.liblinphone_flutter" + + compileSdk = 36 + + compileOptions { + sourceCompatibility = JavaVersion.VERSION_17 + targetCompatibility = JavaVersion.VERSION_17 + } + + kotlinOptions { + jvmTarget = JavaVersion.VERSION_17.toString() + } + + sourceSets { + getByName("main") { + java.srcDirs("src/main/kotlin") + } + getByName("test") { + java.srcDirs("src/test/kotlin") + } + } + + defaultConfig { + minSdk = 24 + } + + testOptions { + unitTests { + isIncludeAndroidResources = true + all { + it.useJUnitPlatform() + + it.outputs.upToDateWhen { false } + + it.testLogging { + events("passed", "skipped", "failed", "standardOut", "standardError") + showStandardStreams = true + } + } + } + } +} + +dependencies { + testImplementation("org.jetbrains.kotlin:kotlin-test") + testImplementation("org.mockito:mockito-core:5.0.0") +} diff --git a/android/settings.gradle.kts b/android/settings.gradle.kts new file mode 100644 index 0000000..1f4f06d --- /dev/null +++ b/android/settings.gradle.kts @@ -0,0 +1 @@ +rootProject.name = 'liblinphone_flutter' diff --git a/android/src/test/kotlin/xyz/nuark/liblinphone_flutter/LiblinphoneFlutterPluginTest.kt b/android/src/test/kotlin/xyz/nuark/liblinphone_flutter/LiblinphoneFlutterPluginTest.kt index dee7857..641ccc3 100644 --- a/android/src/test/kotlin/xyz/nuark/liblinphone_flutter/LiblinphoneFlutterPluginTest.kt +++ b/android/src/test/kotlin/xyz/nuark/liblinphone_flutter/LiblinphoneFlutterPluginTest.kt @@ -1,4 +1,4 @@ -package com.example.liblinphone_flutter +package xyz.nuark.liblinphone_flutter import io.flutter.plugin.common.MethodCall import io.flutter.plugin.common.MethodChannel