Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Arjan Tijms <arjan.tijms@omnifish.ee>
- Loading branch information
1 parent
56e557c
commit bfbcc07
Showing
4 changed files
with
357 additions
and
0 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,270 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
Copyright (c) 2021, 2023 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 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<parent> | ||
<groupId>org.glassfish.main.tests.tck</groupId> | ||
<artifactId>tck</artifactId> | ||
<version>7.0.11-SNAPSHOT</version> | ||
</parent> | ||
|
||
<artifactId>glassfish-external-tck-pages-debugging</artifactId> | ||
<packaging>pom</packaging> | ||
|
||
<name>TCK: pages debugging</name> | ||
|
||
<properties> | ||
<ant.home>${project.build.directory}/apache-ant-${ant.version}</ant.home> | ||
<ant.zip.url>https://archive.apache.org/dist/ant/binaries/apache-ant-${ant.version}-bin.zip</ant.zip.url> | ||
|
||
<tck.home>${project.build.directory}</tck.home> | ||
|
||
<glassfish.home>${project.build.directory}/glassfish7</glassfish.home> | ||
<glassfish.version>${project.version}</glassfish.version> | ||
<glassfish.asadmin>${glassfish.home}/glassfish/bin/asadmin</glassfish.asadmin> | ||
|
||
<jacoco.includes>org/glassfish/**\:com/sun/enterprise/**</jacoco.includes> | ||
|
||
<port.admin>14848</port.admin> | ||
<port.derby>11527</port.derby> | ||
<port.http>18080</port.http> | ||
<port.https>18181</port.https> | ||
<port.jms>17676</port.jms> | ||
<port.jmx>18686</port.jmx> | ||
<port.orb>13700</port.orb> | ||
<port.orb.mutual>13920</port.orb.mutual> | ||
<port.orb.ssl>13820</port.orb.ssl> | ||
<port.harness.log>12000</port.harness.log> | ||
</properties> | ||
|
||
<dependencies> | ||
<dependency> | ||
<groupId>org.glassfish.main.distributions</groupId> | ||
<artifactId>glassfish</artifactId> | ||
<version>${glassfish.version}</version> | ||
<type>zip</type> | ||
<scope>test</scope> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.glassfish.main.tests.tck</groupId> | ||
<artifactId>jakarta-pages-debugging-tck</artifactId> | ||
<version>${project.version}</version> | ||
<type>zip</type> | ||
</dependency> | ||
</dependencies> | ||
|
||
<build> | ||
<plugins> | ||
<plugin> | ||
<groupId>com.googlecode.maven-download-plugin</groupId> | ||
<artifactId>download-maven-plugin</artifactId> | ||
<executions> | ||
<execution> | ||
<id>download-ant</id> | ||
<phase>generate-resources</phase> | ||
<goals> | ||
<goal>wget</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
<configuration> | ||
<skip>${skipITs}</skip> | ||
<url>${ant.zip.url}</url> | ||
<unpack>true</unpack> | ||
<outputDirectory>${project.build.directory}</outputDirectory> | ||
</configuration> | ||
</plugin> | ||
|
||
<plugin> | ||
<artifactId>maven-dependency-plugin</artifactId> | ||
<configuration> | ||
<skip>${skipITs}</skip> | ||
</configuration> | ||
<executions> | ||
<execution> | ||
<id>unpack-glassfish</id> | ||
<phase>pre-integration-test</phase> | ||
<goals> | ||
<goal>unpack-dependencies</goal> | ||
</goals> | ||
<configuration> | ||
<includeArtifactIds>glassfish,jakarta-pages-debugging-tck</includeArtifactIds> | ||
<outputDirectory>${project.build.directory}</outputDirectory> | ||
</configuration> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
|
||
<plugin> | ||
<artifactId>maven-antrun-plugin</artifactId> | ||
<dependencies> | ||
<dependency> | ||
<groupId>org.apache.ant</groupId> | ||
<artifactId>ant</artifactId> | ||
<version>${ant.version}</version> | ||
</dependency> | ||
<dependency> | ||
<groupId>ant-contrib</groupId> | ||
<artifactId>ant-contrib</artifactId> | ||
<version>1.0b3</version> | ||
<exclusions> | ||
<exclusion> | ||
<groupId>ant</groupId> | ||
<artifactId>ant</artifactId> | ||
</exclusion> | ||
</exclusions> | ||
</dependency> | ||
</dependencies> | ||
<configuration> | ||
<skip>${skipITs}</skip> | ||
</configuration> | ||
<executions> | ||
<execution> | ||
<id>prepare-tck-and-glassfish</id> | ||
<phase>pre-integration-test</phase> | ||
<configuration> | ||
<target xmlns:if="ant:if" xmlns:unless="ant:unless"> | ||
<taskdef resource="net/sf/antcontrib/antcontrib.properties" classpathref="maven.plugin.classpath" /> | ||
|
||
<limit maxwait="60"> | ||
<exec executable="${glassfish.asadmin}" dir="${glassfish.home}/glassfish/bin"> | ||
<arg value="delete-domain"/> | ||
<arg value="domain1" /> | ||
</exec> | ||
<exec executable="${glassfish.asadmin}" dir="${glassfish.home}/glassfish/bin"> | ||
<arg value="create-domain"/> | ||
<arg value="--domainproperties=domain.adminPort=${port.admin}:domain.instancePort=${port.http}:http.ssl.port=${port.https}:jms.port=${port.jms}:domain.jmxPort=${port.jmx}:orb.listener.port=${port.orb}:orb.ssl.port=${port.orb.ssl}:orb.mutualauth.port=${port.orb.mutual}" /> | ||
<arg value="--user=admin" /> | ||
<arg value="--nopassword" /> | ||
<arg value="domain1" /> | ||
</exec> | ||
|
||
<exec executable="${glassfish.asadmin}" dir="${glassfish.home}/glassfish/bin"> | ||
<arg value="start-domain"/> | ||
</exec> | ||
|
||
<if> | ||
<isset property="jacoco.version" /> | ||
<then> | ||
<exec executable="${glassfish.asadmin}" dir="${glassfish.home}/glassfish/bin"> | ||
<arg value="create-jvm-options" /> | ||
<arg value="--port=${port.admin}" /> | ||
<arg value=""-javaagent\:${settings.localRepository}/org/jacoco/org.jacoco.agent/${jacoco.version}/org.jacoco.agent-${jacoco.version}-runtime.jar=destfile=${project.build.directory}/jacoco-it.exec,includes=${jacoco.includes}"" /> | ||
</exec> | ||
</then> | ||
</if> | ||
<exec executable="${glassfish.asadmin}" dir="${glassfish.home}/glassfish/bin"> | ||
<arg value="stop-domain"/> | ||
<arg value="domain1"/> | ||
</exec> | ||
|
||
<replace file="${glassfish.home}/glassfish/domains/domain1/config/default-web.xml"> | ||
<replacetoken><![CDATA[<servlet-class>org.glassfish.wasp.servlet.JspServlet</servlet-class>]]></replacetoken> | ||
<replacevalue><![CDATA[<servlet-class>org.glassfish.wasp.servlet.JspServlet</servlet-class> | ||
<init-param> | ||
<param-name>dumpSmap</param-name> | ||
<param-value>true</param-value> | ||
</init-param> | ||
]]></replacevalue> | ||
</replace> | ||
</limit> | ||
</target> | ||
</configuration> | ||
<goals> | ||
<goal>run</goal> | ||
</goals> | ||
</execution> | ||
|
||
<execution> | ||
<id>configure-tck-tests</id> | ||
<phase>pre-integration-test</phase> | ||
<goals> | ||
<goal>run</goal> | ||
</goals> | ||
<configuration> | ||
<target xmlns:if="ant:if" xmlns:unless="ant:unless"> | ||
<taskdef resource="net/sf/antcontrib/antcontrib.properties" classpathref="maven.plugin.classpath" /> | ||
<limit maxwait="20"> | ||
<exec executable="${glassfish.asadmin}" dir="${glassfish.home}/glassfish/bin"> | ||
<arg value="start-domain"/> | ||
<arg value="--suspend" if:set="glassfish.suspend"/> | ||
</exec> | ||
</limit> | ||
|
||
<exec executable="${glassfish.asadmin}" dir="${glassfish.home}/glassfish/bin"> | ||
<arg value="deploy"/> | ||
<arg value="--port=${port.admin}" /> | ||
<arg value="${tck.home}/testclient.war" /> | ||
</exec> | ||
</target> | ||
</configuration> | ||
</execution> | ||
|
||
<execution> | ||
<id>run-tck-tests</id> | ||
<phase>integration-test</phase> | ||
<goals> | ||
<goal>run</goal> | ||
</goals> | ||
<configuration> | ||
<target xmlns:if="ant:if" xmlns:unless="ant:unless"> | ||
<taskdef resource="net/sf/antcontrib/antcontrib.properties" classpathref="maven.plugin.classpath" /> | ||
|
||
<get src="http://localhost:${port.http}/testclient/Hello.jsp" dest="${project.build.directory}/hello.html"/> | ||
|
||
<exec executable="java" outputproperty="verifyResult" failonerror="true"> | ||
<arg value="-cp" /> | ||
<arg value="${project.build.directory}/debugging-tck-2.0.0.jar" /> | ||
<arg value="VerifySMAP" /> | ||
<arg value="${glassfish.home}/glassfish/domains/domain1/generated/jsp/testclient/org/apache/jsp/Hello_jsp.class.smap" /> | ||
</exec> | ||
|
||
<if> | ||
<not> | ||
<contains string="${verifyResult}" substring="is a correctly formatted SMAP"/> | ||
</not> | ||
<then> | ||
<echo message="Running tests failed." /> | ||
<loadfile property="contents" srcFile="${glassfish.home}/glassfish/domains/domain1/logs/server.log" /> | ||
<echo message="${contents}" /> | ||
</then> | ||
</if> | ||
|
||
<exec executable="${glassfish.asadmin}" dir="${glassfish.home}/glassfish/bin"> | ||
<arg value="stop-domain" /> | ||
</exec> | ||
|
||
<if> | ||
<not> | ||
<contains string="${verifyResult}" substring="is a correctly formatted SMAP"/> | ||
</not> | ||
<then> | ||
<fail/> | ||
</then> | ||
</if> | ||
</target> | ||
</configuration> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
</project> |
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
85 changes: 85 additions & 0 deletions
85
appserver/tests/tck/tck-download/jakarta-pages-debugging-tck/pom.xml
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,85 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
Copyright (c) 2021, 2023 Contributors to the Eclipse Foundation. | ||
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.glassfish.main.tests.tck</groupId> | ||
<artifactId>tck-download</artifactId> | ||
<version>7.0.11-SNAPSHOT</version> | ||
</parent> | ||
|
||
<artifactId>jakarta-pages-debugging-tck</artifactId> | ||
<packaging>pom</packaging> | ||
<name>TCK: Install Jakarta Pages Debugging (DSOL) TCK</name> | ||
|
||
|
||
<properties> | ||
<tck.test.pages.file>jakarta-debugging-tck-2.0.0.zip</tck.test.pages.file> | ||
<tck.test.pages.url>https://download.eclipse.org/jakartaee/debugging/2.0/${tck.test.pages.file}</tck.test.pages.url> | ||
</properties> | ||
|
||
<build> | ||
<plugins> | ||
<plugin> | ||
<groupId>com.googlecode.maven-download-plugin</groupId> | ||
<artifactId>download-maven-plugin</artifactId> | ||
<executions> | ||
<execution> | ||
<id>download-pages-debugging-tck</id> | ||
<phase>generate-resources</phase> | ||
<goals> | ||
<goal>wget</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
<configuration> | ||
<skipCache>true</skipCache> | ||
<overwrite>true</overwrite> | ||
<url>${tck.test.pages.url}</url> | ||
<unpack>false</unpack> | ||
<outputDirectory>${project.build.directory}</outputDirectory> | ||
</configuration> | ||
</plugin> | ||
<plugin> | ||
<artifactId>maven-install-plugin</artifactId> | ||
<executions> | ||
<execution> | ||
<id>install-pages-debugging-tck</id> | ||
<phase>process-resources</phase> | ||
<goals> | ||
<goal>install-file</goal> | ||
</goals> | ||
<configuration> | ||
<file>${project.build.directory}/${tck.test.pages.file}</file> | ||
<groupId>${project.groupId}</groupId> | ||
<artifactId>${project.artifactId}</artifactId> | ||
<version>${project.version}</version> | ||
<packaging>zip</packaging> | ||
<generatePom>true</generatePom> | ||
</configuration> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
|
||
</project> |
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