Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Limit modules test with Jenkins and Profile change #89

Merged
merged 4 commits into from
Jul 28, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ pipeline {
wrap([$class: 'Xvnc', useXauthority: true]) {
sh """
mvn clean verify --batch-mode --fail-at-end -Dmaven.repo.local=$WORKSPACE/.m2/repository \
-Pbuild-individual-bundles -Pbree-libs -Papi-check\
-Pbuild-individual-bundles Ptest-on-javase-19 -Pbree-libs -Papi-check\
SarikaSinha marked this conversation as resolved.
Show resolved Hide resolved
-Dcompare-version-with-baselines.skip=true \
-Dproject.build.sourceEncoding=UTF-8 \
-DtrimStackTrace=false
Expand Down
29 changes: 29 additions & 0 deletions org.eclipse.jdt.debug.tests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,33 @@
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>test-on-javase-19</id>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-toolchains-plugin</artifactId>
<version>1.1</version>
<executions>
<execution>
<phase>validate</phase>
<goals>
<goal>toolchain</goal>
</goals>
</execution>
</executions>
<configuration>
<toolchains>
<jdk>
<id>JavaSE-19</id>
</jdk>
</toolchains>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ public class ModuleOptionsTests extends AbstractDebugTest {
+ "jdk.xml.dom";
private static final String ASSUMED_DEFAULT_MODULES_19 = "java.se," //
+ "jdk.accessibility,jdk.attach,jdk.compiler,jdk.dynalink,jdk.httpserver," //
+ "jdk.incubator.vector," // jdk.incubator.foreign removed in 19
+ "jdk.incubator.concurrent,jdk.incubator.vector," // jdk.incubator.foreign removed and jdk.incubator.concurrent added in 19
+ "jdk.jartool,jdk.javadoc,jdk.jconsole,jdk.jdi," //
+ "jdk.jfr," //
+ "jdk.jshell,jdk.jsobject,jdk.management," //
Expand Down Expand Up @@ -189,7 +189,10 @@ public void testLimitModules1() throws JavaModelException {
IJavaProject javaProject = getProjectContext();
List<String> defaultModules = getDefaultModules(javaProject);
String expectedModules;
switch (String.join(",", defaultModules)) {
String moduleList = String.join(",", defaultModules);
System.out.println("ModuleList: " + moduleList);
System.out.println("ASSUMED_DEFAULT_MODULES_19: " + ASSUMED_DEFAULT_MODULES_19);
switch (moduleList) {
case ASSUMED_DEFAULT_MODULES_9:
expectedModules = "java.se," //
+ "javafx.fxml,javafx.swing,javafx.web," //
Expand Down Expand Up @@ -283,7 +286,7 @@ public void testLimitModules1() throws JavaModelException {
expectedModules = "java.se," //
+ "jdk.accessibility," //
+ "jdk.dynalink," + "jdk.httpserver," //
+ "jdk.incubator.vector," // jdk.incubator.foreign removed in 19
+ "jdk.incubator.concurrent,jdk.incubator.vector," // jdk.incubator.foreign removed and jdk.incubator.concurrent added in 19
+ "jdk.jartool,jdk.jconsole,jdk.jshell," //
+ "jdk.jsobject," //
+ "jdk.management.jfr," //
Expand All @@ -294,7 +297,7 @@ public void testLimitModules1() throws JavaModelException {
+ "jdk.xml.dom";
break;
default:
fail("Unknown set of default modules " + String.join(",", defaultModules));
fail("Unknown set of default modules " + moduleList);
return;
}
assertTrue("expected module was not in defaultModules", defaultModules.remove("jdk.javadoc")); // requires java.compiler and jdk.compiler but
Expand Down