| /* |
| * Copyright 2024 The Android Open Source Project |
| * |
| * Licensed under the Apache License, Version 2.0 (the "License"); |
| * you may not use this file except in compliance with the License. |
| * You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, software |
| * distributed under the License is distributed on an "AS IS" BASIS, |
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| * See the License for the specific language governing permissions and |
| * limitations under the License. |
| */ |
| |
| import androidx.build.Publish |
| import org.jetbrains.kotlin.gradle.tasks.KotlinCompile |
| |
| plugins { |
| id("AndroidXPlugin") |
| } |
| |
| androidXMultiplatform { |
| jvm() |
| |
| sourceSets { |
| commonMain { |
| } |
| |
| commonTest { |
| dependencies { |
| implementation(libs.kotlinStdlibCommon) |
| implementation(projectOrArtifact(":compose:runtime:runtime")) |
| implementation(projectOrArtifact(":compose:runtime:runtime-test-utils")) |
| implementation kotlin("test-junit") |
| implementation(libs.kotlinCoroutinesTest) |
| implementation(libs.kotlinReflect) |
| } |
| } |
| |
| jvmMain { |
| dependsOn(commonMain) |
| dependencies { |
| } |
| } |
| |
| jvmTest { |
| dependsOn(commonTest) |
| dependencies { |
| } |
| } |
| } |
| } |
| |
| // Add current version of Compose compiler plugin, as AndroidXCompose plugin pins to releases. |
| configurations { |
| composePlugin { |
| canBeConsumed = false |
| } |
| } |
| |
| dependencies { |
| composePlugin(project(":compose:compiler:compiler")) |
| } |
| |
| def composePluginFiles = configurations.getByName("composePlugin") |
| .incoming |
| .artifactView {} |
| .files |
| |
| tasks.withType(KotlinCompile).configureEach { |
| pluginClasspath.from(composePluginFiles) |
| } |
| |
| androidx { |
| name = "Compose compiler executable tests" |
| publish = Publish.NONE |
| inceptionYear = "2024" |
| description = "Contains executable Compose compiler tests that use Compose runtime." |
| } |