-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
QuarkusBuildTask uses getBuildForkOptions
- Loading branch information
Showing
7 changed files
with
71 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
...tests/gradle/src/main/resources/basic-java-application-with-fork-options/build.gradle.kts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
plugins { | ||
java | ||
id("io.quarkus") | ||
} | ||
|
||
repositories { | ||
mavenCentral() | ||
mavenLocal() | ||
} | ||
|
||
val quarkusPlatformGroupId: String by project | ||
val quarkusPlatformArtifactId: String by project | ||
val quarkusPlatformVersion: String by project | ||
|
||
dependencies { | ||
implementation(enforcedPlatform("${quarkusPlatformGroupId}:${quarkusPlatformArtifactId}:${quarkusPlatformVersion}")) | ||
} | ||
|
||
quarkus { | ||
buildForkOptions { | ||
println("message!") | ||
} | ||
} |
2 changes: 2 additions & 0 deletions
2
...ests/gradle/src/main/resources/basic-java-application-with-fork-options/gradle.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
quarkusPlatformArtifactId=quarkus-bom | ||
quarkusPlatformGroupId=io.quarkus |
16 changes: 16 additions & 0 deletions
16
...-tests/gradle/src/main/resources/basic-java-application-with-fork-options/settings.gradle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
pluginManagement { | ||
repositories { | ||
mavenLocal { | ||
content { | ||
includeGroupByRegex 'io.quarkus.*' | ||
includeGroup 'org.hibernate.orm' | ||
} | ||
} | ||
mavenCentral() | ||
gradlePluginPortal() | ||
} | ||
plugins { | ||
id 'io.quarkus' version "${quarkusPluginVersion}" | ||
} | ||
} | ||
rootProject.name='code-with-quarkus' |
9 changes: 9 additions & 0 deletions
9
...resources/basic-java-application-with-fork-options/src/main/java/org/acme/EntryPoint.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
package org.acme; | ||
|
||
|
||
|
||
public class EntryPoint { | ||
public static void main(String[] args) { | ||
|
||
} | ||
} |
16 changes: 16 additions & 0 deletions
16
...le/src/test/java/io/quarkus/gradle/BuildForkOptionsAreIncludedInQuarkusBuildTaskTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package io.quarkus.gradle; | ||
|
||
import static org.assertj.core.api.Assertions.assertThat; | ||
|
||
import org.junit.jupiter.api.Test; | ||
|
||
public class BuildForkOptionsAreIncludedInQuarkusBuildTaskTest extends QuarkusGradleWrapperTestBase { | ||
|
||
@Test | ||
public void testBuildForkOptionsAreProcessed() throws Exception { | ||
var projectDir = getProjectDir("basic-java-application-with-fork-options"); | ||
var buildResult = runGradleWrapper(projectDir, "clean", "quarkusBuild"); | ||
assertThat(BuildResult.isSuccessful(buildResult.getTasks().get(":quarkusGenerateCode"))).isTrue(); | ||
assertThat(buildResult.getOutput().contains("message!")).isTrue(); | ||
} | ||
} |