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

Cleanup Core Profle TCK runner #58

Merged
merged 3 commits into from
Oct 27, 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
10 changes: 2 additions & 8 deletions wf-core-tck-runner/cdi-langmodel-tck/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -84,14 +84,8 @@
<version>3.0.0-M6</version>
<configuration>
<argLine>
--add-exports=java.desktop/sun.awt=ALL-UNNAMED
--add-opens=java.base/java.io=ALL-UNNAMED
--add-opens=java.base/java.lang=ALL-UNNAMED
--add-opens=java.base/java.lang.invoke=ALL-UNNAMED
--add-opens=java.base/java.security=ALL-UNNAMED
--add-opens=java.base/java.util=ALL-UNNAMED
--add-opens=java.management/javax.management=ALL-UNNAMED
--add-opens=java.naming/javax.naming=ALL-UNNAMED
${addjdkexports}
${addjdkopens}
</argLine>
<enableAssertions>true</enableAssertions>
<forkCount>1</forkCount>
Expand Down
26 changes: 10 additions & 16 deletions wf-core-tck-runner/cdi-tck/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@
<dependency>
<groupId>org.jboss.shrinkwrap.descriptors</groupId>
<artifactId>shrinkwrap-descriptors-impl-javaee</artifactId>
<version>2.0.0</version>
<version>${shrinkwrap.ee.descriptors.impl.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.protocol</groupId>
Expand Down Expand Up @@ -239,14 +239,8 @@
<version>3.0.0-M6</version>
<configuration>
<argLine>
--add-exports=java.desktop/sun.awt=ALL-UNNAMED
--add-opens=java.base/java.io=ALL-UNNAMED
--add-opens=java.base/java.lang=ALL-UNNAMED
--add-opens=java.base/java.lang.invoke=ALL-UNNAMED
--add-opens=java.base/java.security=ALL-UNNAMED
--add-opens=java.base/java.util=ALL-UNNAMED
--add-opens=java.management/javax.management=ALL-UNNAMED
--add-opens=java.naming/javax.naming=ALL-UNNAMED
${addjdkexports}
${addjdkopens}
</argLine>
<properties>
<property>
Expand Down Expand Up @@ -371,37 +365,37 @@
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta.annotation-api</artifactId>
<scope>system</scope>
<systemPath>${env.JBOSS_HOME}/modules/system/layers/base/jakarta/annotation/api/main/jakarta.annotation-api-2.1.1.jar</systemPath>
<systemPath>${env.JBOSS_HOME}/${ANNOTATION_API}</systemPath>
</dependency>
<dependency>
<groupId>jakarta.el</groupId>
<artifactId>jakarta.el-api</artifactId>
<scope>system</scope>
<systemPath>${env.JBOSS_HOME}/modules/system/layers/base/jakarta/el/api/main/jboss-el-api_5.0_spec-4.0.0.CR1.jar</systemPath>
<systemPath>${env.JBOSS_HOME}/${EXPRESSION_LANGUAGE_API}</systemPath>
</dependency>
<dependency>
<groupId>jakarta.interceptor</groupId>
<artifactId>jakarta.interceptor-api</artifactId>
<scope>system</scope>
<systemPath>${env.JBOSS_HOME}/modules/system/layers/base/jakarta/interceptor/api/main/jakarta.interceptor-api-2.1.0.jar</systemPath>
<systemPath>${env.JBOSS_HOME}/${INTERCEPTER_API}</systemPath>
</dependency>
<dependency>
<groupId>jakarta.inject</groupId>
<artifactId>jakarta.inject-api</artifactId>
<scope>system</scope>
<systemPath>${env.JBOSS_HOME}/modules/system/layers/base/jakarta/inject/api/main/jakarta.inject-api-2.0.1.jar</systemPath>
<systemPath>${env.JBOSS_HOME}/${INJECT_API}</systemPath>
</dependency>
<dependency>
<groupId>jakarta.enterprise</groupId>
<artifactId>jakarta.enterprise.lang-model</artifactId>
<scope>system</scope>
<systemPath>${env.JBOSS_HOME}/modules/system/layers/base/jakarta/enterprise/api/main/jakarta.enterprise.lang-model-4.0.0.jar</systemPath>
<systemPath>${env.JBOSS_HOME}/${CDI_LANG_MODEL_API}</systemPath>
</dependency>
<dependency>
<groupId>jakarta.enterprise</groupId>
<artifactId>jakarta.enterprise.cdi-api</artifactId>
<scope>system</scope>
<systemPath>${env.JBOSS_HOME}/modules/system/layers/base/jakarta/enterprise/api/main/jakarta.enterprise.cdi-api-4.0.0.jar</systemPath>
<systemPath>${env.JBOSS_HOME}/${CDI_API}</systemPath>
</dependency>
</dependencies>

Expand Down Expand Up @@ -458,7 +452,7 @@
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta.annotation-api</artifactId>
<scope>system</scope>
<systemPath>${env.JBOSS_HOME}/modules/system/layers/base/jakarta/annotation/api/main/jakarta.annotation-api-2.1.1.jar</systemPath>
<systemPath>${env.JBOSS_HOME}/${ANNOTATION_API}</systemPath>
</dependency>
</dependencies>

Expand Down
10 changes: 2 additions & 8 deletions wf-core-tck-runner/core-tck/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -173,14 +173,8 @@
<artifactId>maven-failsafe-plugin</artifactId>
<configuration>
<argLine>
--add-exports=java.desktop/sun.awt=ALL-UNNAMED
--add-opens=java.base/java.io=ALL-UNNAMED
--add-opens=java.base/java.lang=ALL-UNNAMED
--add-opens=java.base/java.lang.invoke=ALL-UNNAMED
--add-opens=java.base/java.security=ALL-UNNAMED
--add-opens=java.base/java.util=ALL-UNNAMED
--add-opens=java.management/javax.management=ALL-UNNAMED
--add-opens=java.naming/javax.naming=ALL-UNNAMED
${addjdkexports}
${addjdkopens}
</argLine>
<properties>
<configurationParameters>
Expand Down
10 changes: 2 additions & 8 deletions wf-core-tck-runner/jsonp-tck/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -132,14 +132,8 @@
<excludedGroups>${excluded.groups}</excludedGroups>

<argLine>
--add-exports=java.desktop/sun.awt=ALL-UNNAMED
--add-opens=java.base/java.io=ALL-UNNAMED
--add-opens=java.base/java.lang=ALL-UNNAMED
--add-opens=java.base/java.lang.invoke=ALL-UNNAMED
--add-opens=java.base/java.security=ALL-UNNAMED
--add-opens=java.base/java.util=ALL-UNNAMED
--add-opens=java.management/javax.management=ALL-UNNAMED
--add-opens=java.naming/javax.naming=ALL-UNNAMED
${addjdkexports}
${addjdkopens}
</argLine>
<properties>
</properties>
Expand Down
9 changes: 7 additions & 2 deletions wf-core-tck-runner/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,10 @@
<properties>
<maven.compiler.release>11</maven.compiler.release>

<!-- Java workarounds -->
<addjdkexports>--add-exports=java.desktop/sun.awt=ALL-UNNAMED </addjdkexports>
<addjdkopens>--add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.lang.invoke=ALL-UNNAMED --add-opens=java.base/java.security=ALL-UNNAMED --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.management/javax.management=ALL-UNNAMED --add-opens=java.naming/javax.naming=ALL-UNNAMED </addjdkopens>

<!-- Jakarta EE APIs Core -->
<annotations.api.version>2.1.1</annotations.api.version>
<interceptors.api.version>2.1.0</interceptors.api.version>
Expand All @@ -80,6 +84,7 @@
<!-- Test tools/dependencies -->
<arquillian.version>1.7.0.Alpha10</arquillian.version>
<arquillian.container.se.api.version>1.0.1.Final</arquillian.container.se.api.version>
<shrinkwrap.ee.descriptors.impl.version>2.0.0</shrinkwrap.ee.descriptors.impl.version>
<apache.httpclient.version>3.1</apache.httpclient.version>
<glassfish.jakarta.el.version>4.0.2</glassfish.jakarta.el.version>
<yasson.version>3.0.0-RC1</yasson.version>
Expand All @@ -97,8 +102,8 @@
<wildfly.plugin.version>3.0.0.Final</wildfly.plugin.version>
<!-- WildFly JSON-P/JSON-B api jars -->
<wildfly.home>${env.JBOSS_HOME}</wildfly.home>
<wildfly.json-api.jar>${wildfly.home}/modules/system/layers/base/jakarta/json/api/main/jakarta.json-api-2.1.1.jar</wildfly.json-api.jar>
<wildfly.json-bind-api.jar>${wildfly.home}/modules/system/layers/base/jakarta/json/bind/api/main/jakarta.json.bind-api-3.0.0.jar</wildfly.json-bind-api.jar>
<wildfly.json-api.jar>${wildfly.home}/${JSONP_API}</wildfly.json-api.jar>
<wildfly.json-bind-api.jar>${wildfly.home}/${JSONB_API}</wildfly.json-bind-api.jar>
jamezp marked this conversation as resolved.
Show resolved Hide resolved

<!--gc.args>-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5006</gc.args-->
<failsafe.plugin.jdk17.args/>
Expand Down
12 changes: 3 additions & 9 deletions wf-core-tck-runner/rest-tck/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -200,14 +200,8 @@
<test>ee.jakarta.tck.coreprofile.rs.CoreProfileRestTCKSuite</test>

<argLine>
--add-exports=java.desktop/sun.awt=ALL-UNNAMED
--add-opens=java.base/java.io=ALL-UNNAMED
--add-opens=java.base/java.lang=ALL-UNNAMED
--add-opens=java.base/java.lang.invoke=ALL-UNNAMED
--add-opens=java.base/java.security=ALL-UNNAMED
--add-opens=java.base/java.util=ALL-UNNAMED
--add-opens=java.management/javax.management=ALL-UNNAMED
--add-opens=java.naming/javax.naming=ALL-UNNAMED
${addjdkexports}
${addjdkopens}
</argLine>
<systemPropertyVariables>
<arquillian.launch>wildfly-core-profile</arquillian.launch>
Expand All @@ -225,7 +219,7 @@
<porting.ts.url.class.1>ee.jakarta.tck.ws.rs.lib.implementation.sun.common.SunRIURL</porting.ts.url.class.1>
<optional.tech.packages.to.ignore>jakarta.xml.bind</optional.tech.packages.to.ignore>
<!--suppress UnresolvedMavenProperty -->
<signature.sigTestClasspath>${env.JBOSS_HOME}/modules/system/layers/base/jakarta/ws/rs/api/main/jakarta.ws.rs-api-${rest.api.version}.jar${path.separator}${env.JBOSS_HOME}/modules/system/layers/base/jakarta/xml/bind/api/main/jakarta.xml.bind-api-4.0.0.jar${path.separator}${jimage.dir}/java.base${path.separator}${jimage.dir}/java.rmi${path.separator}${jimage.dir}/java.sql${path.separator}${jimage.dir}/java.naming</signature.sigTestClasspath>
<signature.sigTestClasspath>${env.JBOSS_HOME}/${REST_API}${path.separator}${env.JBOSS_HOME}/${XML_BIND_API}${path.separator}${jimage.dir}/java.base${path.separator}${jimage.dir}/java.rmi${path.separator}${jimage.dir}/java.sql${path.separator}${jimage.dir}/java.naming</signature.sigTestClasspath>
jamezp marked this conversation as resolved.
Show resolved Hide resolved

</systemPropertyVariables>
<systemProperties>
Expand Down
61 changes: 61 additions & 0 deletions wf-core-tck-runner/run_all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,67 @@ if [[ -z "${JBOSS_HOME}" ]]; then
exit 1
fi

# locate SPEC API jars if not already specified
if [[ -z "${ANNOTATION_API}" ]]; then
pushd ${JBOSS_HOME}
export ANNOTATION_API=`find * -name jakarta*annotation*api*.jar`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this work with the embedded \n new lines?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

which \n new lines do you mean?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When you do a find it will print each found file on a new line. You'd end up with the environment variable looking something like:

ANNOTATION_API=some/path/cool.jar
some/path/other.jar
some/path/another.jar

I would think only the first one, cool.jar in the example, would be seen.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If multiple jars match the pattern than we need to update the find expression. That sounds like a condition we should check for

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I guess all these do just return a single JAR. Maybe something we more need to keep an eye on then.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed and the run will fail with an error if we introduce additional jars that have similar names such that more than one line is in the result.

popd
fi

if [[ -z "${EXPRESSION_LANGUAGE_API}" ]]; then
pushd ${JBOSS_HOME}
export EXPRESSION_LANGUAGE_API=`find * -name *el-api*.jar`
popd
fi

if [[ -z "${INTERCEPTER_API}" ]]; then
pushd ${JBOSS_HOME}
export INTERCEPTER_API=`find * -name *interceptor-api*.jar`
popd
fi

if [[ -z "${INJECT_API}" ]]; then
pushd ${JBOSS_HOME}
export INJECT_API=`find * -name *inject-api*.jar`
popd
fi

if [[ -z "${CDI_API}" ]]; then
pushd ${JBOSS_HOME}
export CDI_API=`find * -name *enterprise*cdi*api*.jar`
popd
fi

if [[ -z "${CDI_LANG_MODEL_API}" ]]; then
pushd ${JBOSS_HOME}
export CDI_LANG_MODEL_API=`find * -name *enterprise*lang*model*.jar`
popd
fi

if [[ -z "${JSONP_API}" ]]; then
pushd ${JBOSS_HOME}
export JSONP_API=`find * -name *json-api*.jar`
popd
fi

if [[ -z "${JSONB_API}" ]]; then
pushd ${JBOSS_HOME}
export JSONB_API=`find * -name *json.bind*api*.jar`
popd
fi

if [[ -z "${REST_API}" ]]; then
pushd ${JBOSS_HOME}
export REST_API=`find * -name *ws.rs-api*.jar`
popd
fi

if [[ -z "${XML_BIND_API}" ]]; then
pushd ${JBOSS_HOME}
export XML_BIND_API=`find * -name *xml*bind*api*.jar`
popd
fi

echo "+++ Environment:"
uname -a
echo "JAVA_HOME=$JAVA_HOME"
Expand Down