Skip to content

Commit

Permalink
Merge pull request #1536 from alwin-joseph/update_runners_tags
Browse files Browse the repository at this point in the history
Simplify glassfish runners for jaxrs/javaee modules, add Junit tags for jaxrs based on keyword.properties
  • Loading branch information
alwin-joseph authored Sep 18, 2024
2 parents c72c278 + 968a1f2 commit 6c3fd57
Show file tree
Hide file tree
Showing 20 changed files with 86 additions and 215 deletions.
69 changes: 6 additions & 63 deletions glassfish-runner/javaee-module-tck/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@
<packaging>jar</packaging>

<properties>
<!-- Use JDK17 to run with GF 8.0.0-JDK17-M5 -->
<glassfish.container.version>8.0.0-JDK17-M5</glassfish.container.version>
<!-- Use JDK21 to run with GF 8.0.0-M5 -->
<!-- <glassfish.container.version>8.0.0-M5</glassfish.container.version> -->
<!-- Use JDK17 to run with GF 8.0.0-JDK17-M7 -->
<glassfish.container.version>8.0.0-JDK17-M7</glassfish.container.version>
<!-- Use JDK21 to run with GF 8.0.0-M7 -->
<!-- <glassfish.container.version>8.0.0-M7</glassfish.container.version> -->
<glassfish.toplevel.dir>glassfish8</glassfish.toplevel.dir>
<jakarta.platform.version>11.0.0-M2</jakarta.platform.version>
<junit.jupiter.version>5.9.1</junit.jupiter.version>
Expand Down Expand Up @@ -104,65 +104,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<executions>
<execution>
<id>1-StopDomain</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>stop-domain</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>2-StartDomain</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>start-domain</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>3-EnableTraceRequests</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>set</argument>
<argument>server-config.network-config.protocols.protocol.http-listener-1.http.trace-enabled=true</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>4-StopDomain</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>stop-domain</argument>
</arguments>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<version>3.0.0-M5</version>
Expand All @@ -178,6 +119,8 @@
<systemPropertyVariables>
<GLASSFISH_HOME>${project.build.directory}/${glassfish.toplevel.dir}</GLASSFISH_HOME>
<glassfish.home>${project.build.directory}/${glassfish.toplevel.dir}</glassfish.home>
<glassfish.maxHeapSize>2048m</glassfish.maxHeapSize>
<glassfish.postBootCommands>set server-config.network-config.protocols.protocol.http-listener-1.http.trace-enabled=true</glassfish.postBootCommands>
<junit.log.traceflag>true</junit.log.traceflag>
<harness.log.traceflag>true</harness.log.traceflag>
<cts.harness.debug>true</cts.harness.debug>
Expand Down
160 changes: 8 additions & 152 deletions glassfish-runner/jaxrs-platform-tck/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@
by running jaxrs-platform-tck</description>

<properties>
<!-- Use JDK17 to run with GF-8.0.0-JDK17-M5 -->
<!-- <glassfish.container.version>8.0.0-JDK17-M5</glassfish.container.version> -->
<!-- Use JDK21 to run with GF-8.0.0-M5 -->
<glassfish.container.version>8.0.0-M5</glassfish.container.version>
<!-- Use JDK17 to run with GF-8.0.0-JDK17-M7 -->
<glassfish.container.version>8.0.0-JDK17-M7</glassfish.container.version>
<!-- Use JDK21 to run with GF-8.0.0-M7 -->
<!-- <glassfish.container.version>8.0.0-M7</glassfish.container.version> -->
<glassfish.toplevel.dir>glassfish8</glassfish.toplevel.dir>
<junit.jupiter.version>5.9.1</junit.jupiter.version>
<tck.artifactId>jaxrs-platform-tck</tck.artifactId>
Expand Down Expand Up @@ -143,154 +143,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<executions>
<execution>
<id>03-StopDomain1</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>stop-domain</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>04-StartDomain1</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>start-domain</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>05-Enable Trace requests</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>set</argument>
<argument>server-config.network-config.protocols.protocol.http-listener-1.http.trace-enabled=true</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>06-Delete User j2ee</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>--passwordfile</argument>
<argument>${project.basedir}/j2ee.pass</argument>
<argument>delete-file-user</argument>
<argument>j2ee</argument>
</arguments>
<successCodes>
<successCode>0</successCode>
<successCode>1</successCode>
</successCodes>
</configuration>
</execution>
<execution>
<id>07-Add User j2ee</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>--passwordfile</argument>
<argument>${project.basedir}/j2ee.pass</argument>
<argument>create-file-user</argument>
<argument>--groups</argument>
<argument>staff:mgr</argument>
<argument>j2ee</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>08-Delete User javajoe</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>--passwordfile</argument>
<argument>${project.basedir}/javajoe.pass</argument>
<argument>delete-file-user</argument>
<argument>javajoe</argument>
</arguments>
<successCodes>
<successCode>0</successCode>
<successCode>1</successCode>
</successCodes>
</configuration>
</execution>
<execution>
<id>09-Add User javajoe</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>--passwordfile</argument>
<argument>${project.basedir}/javajoe.pass</argument>
<argument>create-file-user</argument>
<argument>--groups</argument>
<argument>guest</argument>
<argument>javajoe</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>10-list users</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>list-file-users</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>11-StopDomain</id>
<goals>
<goal>exec</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<executable>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/bin/asadmin</executable>
<arguments>
<argument>stop-domain</argument>
</arguments>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<executions>
Expand Down Expand Up @@ -327,6 +179,10 @@
<systemPropertyVariables>
<GLASSFISH_HOME>${project.build.directory}/${glassfish.toplevel.dir}</GLASSFISH_HOME>
<glassfish.home>${project.build.directory}/${glassfish.toplevel.dir}</glassfish.home>
<glassfish.maxHeapSize>2048m</glassfish.maxHeapSize>
<glassfish.postBootCommands>create-file-user --groups staff:mgr:DIRECTOR --passwordfile ${project.build.directory}/../j2ee.pass j2ee
create-file-user --groups guest:OTHERROLE --passwordfile ${project.build.directory}/../javajoe.pass javajoe
set server-config.network-config.protocols.protocol.http-listener-1.http.trace-enabled=true</glassfish.postBootCommands>
<servlet_adaptor>org.glassfish.jersey.servlet.ServletContainer</servlet_adaptor>
<webServerHost>localhost</webServerHost>
<webServerPort>8080</webServerPort>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
import org.jboss.shrinkwrap.api.spec.WebArchive;

import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Tag;
import org.junit.jupiter.api.extension.ExtendWith;
import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.BeforeEach;
Expand All @@ -54,6 +55,9 @@
* @since 2.1
*/
@ExtendWith(ArquillianExtension.class)
@Tag("jaxrs")
@Tag("platform")
@Tag("web")
public class JAXRSClientIT extends JaxrsCommonClient {

private static final long serialVersionUID = 21L;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
import org.jboss.shrinkwrap.api.spec.WebArchive;

import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Tag;
import org.junit.jupiter.api.extension.ExtendWith;
import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.BeforeEach;
Expand All @@ -44,6 +45,9 @@
* @since 2.1
*/
@ExtendWith(ArquillianExtension.class)
@Tag("jaxrs")
@Tag("platform")
@Tag("web")
public class JAXRSClientIT extends JaxrsCommonClient {

private static final long serialVersionUID = 21L;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
import org.jboss.shrinkwrap.api.spec.WebArchive;

import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Tag;
import org.junit.jupiter.api.extension.ExtendWith;
import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.BeforeEach;
Expand All @@ -46,6 +47,9 @@
* Test the interceptor is called when any entity provider is called
*/
@ExtendWith(ArquillianExtension.class)
@Tag("jaxrs")
@Tag("platform")
@Tag("web")
public class JAXRSClientIT extends JaxrsCommonClient {

private static final long serialVersionUID = 6890833876230368627L;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
import org.jboss.shrinkwrap.api.spec.WebArchive;

import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Tag;
import org.junit.jupiter.api.extension.ExtendWith;
import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.BeforeEach;
Expand All @@ -65,6 +66,9 @@
* @since 2.1.0
*/
@ExtendWith(ArquillianExtension.class)
@Tag("jaxrs")
@Tag("platform")
@Tag("web")
public class JAXRSClientIT extends JaxrsCommonClient {

private static final long serialVersionUID = 210L;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
import org.jboss.shrinkwrap.api.spec.WebArchive;

import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Tag;
import org.junit.jupiter.api.extension.ExtendWith;
import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.BeforeEach;
Expand All @@ -65,6 +66,9 @@
* @since 2.1.0
*/
@ExtendWith(ArquillianExtension.class)
@Tag("jaxrs")
@Tag("platform")
@Tag("web")
public class JAXRSClientIT extends JaxrsCommonClient {

private static final long serialVersionUID = 210L;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
import java.io.IOException;

import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Tag;
import org.junit.jupiter.api.extension.ExtendWith;
import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.BeforeEach;
Expand All @@ -45,6 +46,9 @@
* Servlet 2.5 spec by default
*/
@ExtendWith(ArquillianExtension.class)
@Tag("jaxrs")
@Tag("platform")
@Tag("web")
public class JAXRSClientIT extends JaxrsCommonClient {

private static final long serialVersionUID = 8849202370030024015L;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@

import static org.junit.jupiter.api.Assertions.assertFalse;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.Tag;
import org.junit.jupiter.api.extension.ExtendWith;
import org.junit.jupiter.api.TestInfo;
import org.junit.jupiter.api.BeforeEach;
Expand All @@ -64,6 +65,9 @@
* Servlet 2.5 spec by default
*/
@ExtendWith(ArquillianExtension.class)
@Tag("jaxrs")
@Tag("platform")
@Tag("web")
public class JAXRSClientIT extends JaxrsCommonClient {

private static final long serialVersionUID = 8496602126019947248L;
Expand Down
Loading

0 comments on commit 6c3fd57

Please sign in to comment.