Skip to content

Commit

Permalink
Merge pull request gradle#27116 Cherry-pick gradle#27094 to release
Browse files Browse the repository at this point in the history
As requested by @blindpirate

Co-authored-by: bot-gradle <[email protected]>
  • Loading branch information
bot-gradle committed Nov 21, 2023
2 parents 834fc0a + 16d023a commit 108b1e3
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

import gradlebuild.basics.repoRoot
import gradlebuild.cleanup.services.CachesCleaner
import gradlebuild.integrationtests.extension.IntegrationTestExtension
import gradlebuild.integrationtests.setSystemPropertiesOfTestJVM
import gradlebuild.integrationtests.tasks.DistributionTest

Expand Down Expand Up @@ -87,7 +88,7 @@ fun DistributionTest.configureGradleTestEnvironment() {
}

fun DistributionTest.setJvmArgsOfTestJvm() {
jvmArgs("-Xmx512m", "-XX:+HeapDumpOnOutOfMemoryError")
jvmArgs("-Xmx${project.the<IntegrationTestExtension>().testJvmXmx.get()}", "-XX:+HeapDumpOnOutOfMemoryError")
if (!javaVersion.isJava8Compatible) {
jvmArgs("-XX:MaxPermSize=768m")
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ plugins {

extensions.create<IntegrationTestExtension>("integTest").apply {
usesJavadocCodeSnippets.convention(false)
testJvmXmx.convention("512m")
}

val sourceSet = addSourceSet(TestType.INTEGRATION)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,5 @@ import org.gradle.api.provider.Property

abstract class IntegrationTestExtension {
abstract val usesJavadocCodeSnippets: Property<Boolean>
abstract val testJvmXmx: Property<String>
}
2 changes: 2 additions & 0 deletions platforms/software/build-init/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -74,3 +74,5 @@ dependencies {
packageCycles {
excludePatterns.add("org/gradle/api/tasks/wrapper/internal/*")
}

integTest.testJvmXmx = "1g"
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ import org.gradle.buildinit.plugins.internal.modifiers.BuildInitDsl
import org.gradle.buildinit.plugins.internal.modifiers.Language
import org.gradle.integtests.fixtures.DefaultTestExecutionResult
import org.gradle.internal.jvm.Jvm
import org.gradle.test.fixtures.Flaky
import spock.lang.Unroll

import static org.gradle.buildinit.plugins.internal.modifiers.Language.GROOVY
Expand All @@ -38,7 +37,6 @@ abstract class AbstractMultiProjectJvmApplicationInitIntegrationTest extends Abs
return null
}

@Flaky(because = "https://github.com/gradle/gradle-private/issues/4010")
@Unroll("creates multi-project application sample when incubating flag = #incubating")
def "creates multi-project application sample"() {
given:
Expand Down

0 comments on commit 108b1e3

Please sign in to comment.