Skip to content

Commit

Permalink
Merge pull request #1795 from arjantijms/rest_runner_installer
Browse files Browse the repository at this point in the history
Add installer pom for the REST TCK runner
  • Loading branch information
arjantijms authored Jan 21, 2025
2 parents 5e13e0e + 82f85e8 commit 2b21aa5
Show file tree
Hide file tree
Showing 7 changed files with 327 additions and 220 deletions.
37 changes: 37 additions & 0 deletions glassfish-runner/rest-platform-extra-tck/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2024, 2025 Contributors to the Eclipse Foundation.
Copyright (c) 2022 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
http://www.eclipse.org/legal/epl-2.0.
This Source Code may also be made available under the following Secondary
Licenses when the conditions for such availability set forth in the
Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
version 2 with the GNU Classpath Exception, which is available at
https://www.gnu.org/software/classpath/license.html.
SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.eclipse.ee4j</groupId>
<artifactId>project</artifactId>
<version>1.0.9</version>
<relativePath />
</parent>

<artifactId>rest-platform-extra-tck</artifactId>
<version>4.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

<modules>
<module>rest-platform-extra-tck-install</module>
<module>rest-platform-extra-tck-run</module>
</modules>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2021, 2025 Contributors to the Eclipse Foundation. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
http://www.eclipse.org/legal/epl-2.0.
This Source Code may also be made available under the following Secondary
Licenses when the conditions for such availability set forth in the
Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
version 2 with the GNU Classpath Exception, which is available at
https://www.gnu.org/software/classpath/license.html.
SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.eclipse.ee4j</groupId>
<artifactId>project</artifactId>
<version>1.0.9</version>
<relativePath />
</parent>

<artifactId>rest-extra-tck-install</artifactId>
<version>4.0.0-SNAPSHOT</version>
<packaging>pom</packaging>
<name>TCK: Install Jakarta REST Platform Extra TCK</name>

<properties>
<tck.test.rest-extra.file>jakarta-rest-extra-tck-${tck.test.rest-extra.version}.zip</tck.test.rest-extra.file>
<tck.test.rest-extra.url>https://download.eclipse.org/ee4j/jakartaee-tck/jakartaee11/staged/eftl/${tck.test.rest-extra.file}</tck.test.rest-extra.url>
<tck.test.rest-extra.version>4.0.0-M1</tck.test.rest-extra.version>
</properties>

<build>
<plugins>
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>1.13.0</version>
<configuration>
<url>${tck.test.rest-extra.url}</url>
<unpack>true</unpack>
<outputDirectory>${project.build.directory}</outputDirectory>
</configuration>
<executions>
<execution>
<id>download-rest-extra-tck</id>
<goals>
<goal>wget</goal>
</goals>
<phase>generate-resources</phase>
</execution>
</executions>
</plugin>

<plugin>
<artifactId>maven-install-plugin</artifactId>
<version>3.1.3</version>
<executions>
<execution>
<id>install-rest-extra-tck-pom</id>
<goals>
<goal>install-file</goal>
</goals>
<phase>process-resources</phase>
<configuration>
<file>${project.build.directory}/rest-platform-tck-${tck.test.rest-extra.version}.jar</file>
<sources>${project.build.directory}/rest-platform-tck-${tck.test.rest-extra.version}-sources.jar</sources>
<groupId>jakarta.tck</groupId>
<artifactId>rest-platform-tck</artifactId>
<version>${tck.test.rest-extra.version}</version>
<packaging>jar</packaging>
</configuration>
</execution>
</executions>
</plugin>

</plugins>
</build>

</project>
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -0,0 +1,203 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2025 Contributors to the Eclipse Foundation.
Copyright (c) 2024 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0, which is available at
http://www.eclipse.org/legal/epl-2.0.
This Source Code may also be made available under the following Secondary
Licenses when the conditions for such availability set forth in the
Eclipse Public License v. 2.0 are satisfied: GNU General Public License,
version 2 with the GNU Classpath Exception, which is available at
https://www.gnu.org/software/classpath/license.html.
SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.eclipse.ee4j</groupId>
<artifactId>project</artifactId>
<version>1.0.9</version>
<relativePath />
</parent>

<groupId>jakarta</groupId>
<artifactId>glassfish-restful-tests</artifactId>
<version>4.0.0-SNAPSHOT</version>

<name>TCK: Run Jakarta REST Platform Extra TCK</name>
<description>
This verifies the compliance of Glassfish using the extra Jakarta REST tests for Jakarta EE Platform
by running rest-platform-tck
</description>

<properties>
<!-- Use JDK21 to run with GF-8.0.0-M9 -->
<!-- <glassfish.version>8.0.0-M9</glassfish.version> -->
<glassfish.toplevel.dir>glassfish8</glassfish.toplevel.dir>
<!-- Use JDK17 to run with GF-8.0.0-JDK17-M7 -->
<glassfish.version>8.0.0-JDK17-M9</glassfish.version>
<tck.version>4.0.0-M1</tck.version>
</properties>

<!-- The Junit5 test frameworks -->
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.junit</groupId>
<artifactId>junit-bom</artifactId>
<version>5.11.4</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.jboss.arquillian</groupId>
<artifactId>arquillian-bom</artifactId>
<version>1.9.3.Final</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
<groupId>jakarta.tck</groupId>
<artifactId>rest-platform-tck</artifactId>
<version>${tck.version}</version>
<scope>test</scope>
</dependency>

<!-- Junit5 -->
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.junit5</groupId>
<artifactId>arquillian-junit5-container</artifactId>
</dependency>
<dependency>
<groupId>commons-httpclient</groupId>
<artifactId>commons-httpclient</artifactId>
<version>3.1</version>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest</artifactId>
<version>3.0</version>
<scope>test</scope>
</dependency>

<!--
The Arquillian connector that starts GlassFish and deploys archives to it.
-->
<dependency>
<groupId>org.omnifaces.arquillian</groupId>
<artifactId>arquillian-glassfish-server-managed</artifactId>
<version>1.7</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.omnifaces.arquillian</groupId>
<artifactId>glassfish-client-ee11</artifactId>
<version>1.7.1</version>
<scope>test</scope>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.8.1</version>
<executions>
<execution>
<id>01-unpack</id>
<goals>
<goal>unpack</goal>
</goals>
<phase>generate-resources</phase>
<configuration>
<artifactItems>
<artifactItem>
<groupId>org.glassfish.main.distributions</groupId>
<artifactId>${glassfish-artifact-id}</artifactId>
<version>${glassfish.version}</version>
<type>zip</type>
<overWrite>false</overWrite>
<outputDirectory>${project.build.directory}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>

<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<version>3.5.2</version>
<executions>
<execution>
<id>gf-tests</id>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
<configuration>
<dependenciesToScan>jakarta.tck:rest-platform-tck</dependenciesToScan>

<systemPropertyVariables>
<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>
<junit.log.traceflag>true</junit.log.traceflag>

<user>j2ee</user>
<password>j2ee</password>
<authuser>javajoe</authuser>
<authpassword>javajoe</authpassword>

<porting.ts.url.class.1>com.sun.ts.tests.jaxrs.lib.implementation.sun.common.SunRIURL</porting.ts.url.class.1>
</systemPropertyVariables>
</configuration>
</execution>

</executions>
</plugin>
</plugins>
</build>

<profiles>
<profile>
<id>full</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<properties>
<glassfish-artifact-id>glassfish</glassfish-artifact-id>
</properties>
</profile>
<profile>
<id>web</id>
<properties>
<glassfish-artifact-id>web</glassfish-artifact-id>
</properties>
</profile>
</profiles>
</project>
Loading

0 comments on commit 2b21aa5

Please sign in to comment.