paparazzi-tests: move to common module

This commit is contained in:
Harsh Shandilya 2022-08-02 23:53:46 +05:30
parent 60e9c8c625
commit cbdfa67d07
No known key found for this signature in database
GPG key ID: 366D7BBAD1031E80
11 changed files with 7 additions and 36 deletions

View file

@ -8,6 +8,7 @@ plugins {
id("dev.msfjarvis.claw.kotlin-common")
id("dev.msfjarvis.claw.android-library")
alias(libs.plugins.aurora.svg.transcoder)
alias(libs.plugins.paparazzi)
}
val transcodeTask =
@ -38,6 +39,12 @@ dependencies {
implementation(libs.compose.richtext.ui)
implementation(libs.kotlinx.coroutines.core)
implementation(libs.kotlinx.datetime)
testImplementation(kotlin("test-junit"))
testImplementation(libs.testparameterinjector)
}
tasks.withType<Test>().configureEach {
javaLauncher.set(javaToolchains.launcherFor { languageVersion.set(JavaLanguageVersion.of(11)) })
}
android {

View file

@ -1,7 +0,0 @@
# paparazzi-tests
[Paparazzi](https://github.com/cashapp/paparazzi) is a Gradle plugin and library that allows writing
Android UI tests that run on the JVM. However, it does not support Kotlin Multiplatform so we're
using this Android library module to hide the Multiplatform aspect of the project from Paparazzi. In
the future this will be natively supported and we can disperse the tests contained in this module
into existing ones.

View file

@ -1,29 +0,0 @@
@file:Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("dev.msfjarvis.claw.android-library")
id("dev.msfjarvis.claw.kotlin-android")
alias(libs.plugins.paparazzi)
}
androidComponents { beforeVariants(selector().all()) { it.enable = it.buildType == "debug" } }
android {
namespace = "dev.msfjarvis.claw.android.tests"
buildFeatures { compose = true }
composeOptions {
useLiveLiterals = false
kotlinCompilerExtensionVersion = libs.versions.composeCompiler.get()
}
}
dependencies {
testImplementation(kotlin("test-junit"))
testImplementation(libs.kotlinx.datetime)
testImplementation(libs.testparameterinjector)
testImplementation(projects.common)
}
tasks.withType<Test>().configureEach {
javaLauncher.set(javaToolchains.launcherFor { languageVersion.set(JavaLanguageVersion.of(11)) })
}