Skip to content

Commit

Permalink
Fixes #3904 - Cleanup Piranha Core Profile TCK Maven modules (#3905)
Browse files Browse the repository at this point in the history
  • Loading branch information
mnriem committed Sep 7, 2024
1 parent 8b50899 commit 88898f8
Show file tree
Hide file tree
Showing 9 changed files with 427 additions and 476 deletions.
3 changes: 3 additions & 0 deletions extension/redhat-weld/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
<name>Piranha - Extension - RedHat Weld</name>

<properties>
<!-- dependencies -->
<weld.version>6.0.0.Beta4</weld.version>
<!-- other -->
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<weld.version>6.0.0.Beta4</weld.version>
</properties>
Expand Down
158 changes: 74 additions & 84 deletions external/tck/coreprofile/annotations/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,102 +27,92 @@
</dependency>
</dependencies>
</dependencyManagement>
<profiles>
<profile>
<id>unix</id>
<activation>
<os>
<family>unix</family>
</os>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>pre-integration-test</id>
<phase>pre-integration-test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target xmlns:if="ant:if" xmlns:unless="ant:unless">
<echo>Executing UNIX profile</echo>

<!-- Download, unzip and rename TCK -->
<get src="https://download.eclipse.org/jakartaee/annotations/2.1/jakarta-annotations-tck-2.1.1.zip"
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>pre-integration-test</id>
<phase>pre-integration-test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<!-- Download, unzip and rename TCK -->
<get src="https://download.eclipse.org/jakartaee/annotations/2.1/jakarta-annotations-tck-${annotations.tck.version}.zip"
dest="${project.build.directory}/tck.zip"
skipexisting="true"/>
<unzip src="${project.build.directory}/tck.zip"
<unzip src="${project.build.directory}/tck.zip"
dest="${project.build.directory}"/>
<move file="${project.build.directory}/annotations-tck"
<move file="${project.build.directory}/annotations-tck"
tofile="${project.build.directory}/tck"/>

<!-- Download, unzip, rename and chmod Ant 1.10.9 -->
<get src="https://archive.apache.org/dist/ant/binaries/apache-ant-1.10.9-bin.zip"
<!-- Download, unzip, rename and chmod Ant 1.10.9 -->
<get src="https://archive.apache.org/dist/ant/binaries/apache-ant-1.10.9-bin.zip"
dest="${project.build.directory}/ant.zip" skipexisting="true"/>
<unzip src="${project.build.directory}/ant.zip"
<unzip src="${project.build.directory}/ant.zip"
dest="${project.build.directory}"/>
<move file="${project.build.directory}/apache-ant-1.10.9"
<move file="${project.build.directory}/apache-ant-1.10.9"
tofile="${project.build.directory}/ant"/>
<chmod dir="${ant.home}/bin"
<chmod dir="${ant.home}/bin"
perm="ugo+rx"
includes="*"/>

<!-- Setup ts.jte for signature tests -->
<replaceregexp file="${tck.home}/bin/ts.jte"
<!-- Setup ts.jte for signature tests -->
<replaceregexp file="${tck.home}/bin/ts.jte"
match="local\.classes=(.*)"
replace="local\.classes=${signature.home}/jakarta.annotation-api.jar"
byline="true"/>
</target>
</configuration>
</execution>
<execution>
<id>integration-test</id>
<phase>integration-test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<!-- Run all the tests -->
<exec executable="${ant.home}/bin/ant" dir="${test.home}">
<arg value="-Dwork.dir=${tck.home}/work"/>
<arg value="-Dreport.dir=${tck.home}/report"/>
<arg value="runclient"/>
</exec>
</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>pre-integration-test</id>
<phase>pre-integration-test</phase>
<goals>
<goal>copy</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta.annotation-api</artifactId>
<outputDirectory>${signature.home}</outputDirectory>
<destFileName>jakarta.annotation-api.jar</destFileName>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</target>
</configuration>
</execution>
<execution>
<id>integration-test</id>
<phase>integration-test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<!-- Run all the tests -->
<exec dir="${test.home}"
executable="${ant.home}/bin/ant"
failonerror="true">
<arg value="-Dwork.dir=${tck.home}/work"/>
<arg value="-Dreport.dir=${tck.home}/report"/>
<arg value="runclient"/>
</exec>
</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>pre-integration-test</id>
<phase>pre-integration-test</phase>
<goals>
<goal>copy</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta.annotation-api</artifactId>
<outputDirectory>${signature.home}</outputDirectory>
<destFileName>jakarta.annotation-api.jar</destFileName>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
126 changes: 57 additions & 69 deletions external/tck/coreprofile/atinject/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,7 @@
<packaging>pom</packaging>
<name>Piranha Core Profile - Jakarta Inject TCK</name>
<properties>
<ant.home>${project.build.directory}/ant</ant.home>
<signature.home>${project.build.directory}/signature</signature.home>
<tck.home>${project.build.directory}/tck</tck.home>
<test.home>${tck.home}/src/com/sun/ts/tests</test.home>
</properties>
<dependencyManagement>
<dependencies>
Expand All @@ -27,73 +24,64 @@
</dependency>
</dependencies>
</dependencyManagement>
<profiles>
<profile>
<id>unix</id>
<activation>
<os>
<family>unix</family>
</os>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>pre-integration-test</id>
<phase>pre-integration-test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target xmlns:if="ant:if" xmlns:unless="ant:unless">
<echo>Executing UNIX profile</echo>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>pre-integration-test</id>
<phase>pre-integration-test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<echo>Executing UNIX profile</echo>

<!-- Download, unzip and rename TCK -->
<get src="https://download.eclipse.org/jakartaee/dependency-injection/2.0/jakarta.inject-tck-2.0.2-bin.zip"
dest="${project.build.directory}/tck.zip"
skipexisting="true"/>
<unzip src="${project.build.directory}/tck.zip"
dest="${project.build.directory}"/>
<move file="${project.build.directory}/jakarta.inject-tck-2.0.2"
tofile="${project.build.directory}/tck"/>
<!-- Download, unzip and rename TCK -->
<get src="https://download.eclipse.org/jakartaee/dependency-injection/2.0/jakarta.inject-tck-${inject.tck.version}-bin.zip"
dest="${project.build.directory}/tck.zip"
skipexisting="true"/>
<unzip src="${project.build.directory}/tck.zip"
dest="${project.build.directory}"/>
<move file="${project.build.directory}/jakarta.inject-tck-${inject.tck.version}"
tofile="${project.build.directory}/tck"/>

<!-- Install the TCK into local Maven repository -->
<exec executable="mvn">
<arg value="install:install-file"/>
<arg value="-Dfile=${project.build.directory}/tck/jakarta.inject-tck-2.0.2.jar"/>
</exec>
<!-- Install the TCK into local Maven repository -->
<exec executable="mvn">
<arg value="install:install-file"/>
<arg value="-Dfile=${project.build.directory}/tck/jakarta.inject-tck-${inject.tck.version}.jar"/>
</exec>

<!-- Setup example/pom.xml for correct Weld version -->
<replaceregexp file="${tck.home}/example/pom.xml"
match="&lt;weld.version>(.*)&lt;/weld.version>"
replace="&lt;weld.version>5.1.2.Final&lt;/weld.version>"
byline="true"/>
</target>
</configuration>
</execution>
<execution>
<id>integration-test</id>
<phase>integration-test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<!-- Run the tests -->
<exec dir="${project.build.directory}/tck/example"
executable="mvn">
<arg value="verify"/>
</exec>
</target>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<!-- Setup example/pom.xml for correct Weld version -->
<replaceregexp file="${tck.home}/example/pom.xml"
match="&lt;weld.version>(.*)&lt;/weld.version>"
replace="&lt;weld.version>${weld.version}&lt;/weld.version>"
byline="true"/>
</target>
</configuration>
</execution>
<execution>
<id>integration-test</id>
<phase>integration-test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<!-- Run the tests -->
<exec dir="${project.build.directory}/tck/example"
executable="mvn"
failonerror="true">
<arg value="verify"/>
</exec>
</target>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
Loading

0 comments on commit 88898f8

Please sign in to comment.