Skip to content

Commit

Permalink
Ensure plugin is compatible with gradle isolated projects
Browse files Browse the repository at this point in the history
  • Loading branch information
mateuszkwiecinski committed Aug 31, 2024
1 parent 2cf60dc commit 6a10d4c
Showing 1 changed file with 36 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,42 @@ internal class EasyLauncherPluginTest : WithGradleProjectTest() {
assertThat(secondRun.output).contains("Configuration cache entry reused")
}

@Test
fun `plugin is compatible with isolated projects`() {
moduleRoot.resolve("build.gradle").buildScript(
androidBlock = { "" },
easylauncherBlock = {
"""
productFlavors {
debug {
filters(
grayRibbonFilter(),
greenRibbonFilter(),
orangeRibbonFilter(),
yellowRibbonFilter(),
redRibbonFilter(),
blueRibbonFilter(),
customRibbon(label: "second", ribbonColor: "#6600CC", labelColor: "#FFFFFF", position: "bottom"),
chromeLike(),
chromeLike(
label: "JP2",
ribbonColor: "#723D46",
labelColor: "#EEFFFEE",
labelPadding: 25,
overlayHeight: 0.6,
textSizeRatio: 0.15
),
)
}
}
""".trimIndent()
},
)

val result = runTask("assembleDebug", "-Dorg.gradle.unsafe.isolated-projects=true", skipJacoco = true)
assertThat(result.task(":app:easylauncherDebug")?.outcome).isEqualTo(TaskOutcome.SUCCESS)
}

@Test
fun `generates proper tasks`() {
moduleRoot.resolve("build.gradle").buildScript(
Expand Down

0 comments on commit 6a10d4c

Please sign in to comment.