Skip to content

Commit

Permalink
Fixes #4098 - Update Jakarta Annotations TCK to 3.0.0 (#4099)
Browse files Browse the repository at this point in the history
  • Loading branch information
mnriem authored Oct 23, 2024
1 parent 32d3fba commit b9b82e6
Show file tree
Hide file tree
Showing 7 changed files with 215 additions and 140 deletions.
20 changes: 6 additions & 14 deletions .github/workflows/tck-coreprofile.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
name: tck-coreprofile
on:
push:
paths:
- 'external/coreprofile-tck/**'
branches:
- '*'
tags-ignore:
- 'v*'
pull_request:
paths:
- 'external/coreprofile-tck/**'
branches:
- '*'
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
Expand All @@ -35,9 +23,13 @@ jobs:
run: mvn -B -DskipTests=true -ntp install
- name: Run TCK
run: |
cd external/coreprofile-tck/annotations
cd external/tck/annotations
mvn -B -ntp verify
cat target/tck/report/text/summary.txt >> $GITHUB_STEP_SUMMARY
- name: Test Summary
uses: test-summary/action@v2
with:
paths: "external/tck/annotations/runner/target/failsafe-reports/*IT.xml"
if: always()
atinject:
if: github.repository == 'piranhacloud/piranha'
runs-on: ${{ matrix.os }}
Expand Down
124 changes: 0 additions & 124 deletions external/coreprofile-tck/annotations/pom.xml

This file was deleted.

2 changes: 0 additions & 2 deletions external/coreprofile-tck/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
<name>Piranha Core Profile - Core Profile TCK project</name>

<modules>
<module>annotations</module>
<module>atinject</module>
<module>cdi</module>
<module>coreprofile</module>
Expand All @@ -27,7 +26,6 @@

<properties>
<!-- TCK versions -->
<annotations.tck.version>2.1.1</annotations.tck.version>
<cdi.tck.version>4.0.13</cdi.tck.version>
<coreprofile.tck.version>10.0.3</coreprofile.tck.version>
<inject.tck.version>2.0.2</inject.tck.version>
Expand Down
61 changes: 61 additions & 0 deletions external/tck/annotations/installer/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
<?xml version="1.0" encoding="UTF-8"?>

<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>cloud.piranha.external.tck.annotations</groupId>
<artifactId>project</artifactId>
<version>24.11.0-SNAPSHOT</version>
</parent>

<artifactId>piranha-external-tck-annotations-installer</artifactId>
<packaging>pom</packaging>

<name>Piranha - External - TCK - Annotations - Installer</name>

<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/3.0/jakarta-annotations-tck-${annotations.tck.version}.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}/annotations-tck"
tofile="${project.build.directory}/tck"/>

<!-- Install the TCK artifacts into local Maven repository -->
<chmod dir="${project.build.directory}/tck/artifacts"
perm="ugo+rx"
includes="*"/>
<exec dir="${project.build.directory}/tck/artifacts"
executable="./artifact-install.sh"/>
</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<configuration>
<!-- skipping here as the runner project runs the actual tests -->
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</build>
</project>
49 changes: 49 additions & 0 deletions external/tck/annotations/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
<?xml version="1.0" encoding="UTF-8"?>

<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>cloud.piranha.external.tck</groupId>
<artifactId>project</artifactId>
<version>24.11.0-SNAPSHOT</version>
</parent>

<groupId>cloud.piranha.external.tck.annotations</groupId>
<artifactId>project</artifactId>
<packaging>pom</packaging>

<name>Piranha - External - TCK - Annotations - Project</name>

<properties>
<annotations.tck.version>3.0.0</annotations.tck.version>
<sigtest-maven-plugin.version>2.2</sigtest-maven-plugin.version>
</properties>

<modules>
<module>installer</module>
<module>runner</module>
</modules>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>cloud.piranha</groupId>
<artifactId>bom</artifactId>
<version>${project.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>jakarta.tck</groupId>
<artifactId>sigtest-maven-plugin</artifactId>
<version>${sigtest-maven-plugin.version}</version>
</dependency>
<dependency>
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta-annotations-tck</artifactId>
<version>${annotations.tck.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
</project>
98 changes: 98 additions & 0 deletions external/tck/annotations/runner/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
<?xml version="1.0" encoding="UTF-8"?>

<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>cloud.piranha.external.tck.annotations</groupId>
<artifactId>project</artifactId>
<version>24.11.0-SNAPSHOT</version>
</parent>

<artifactId>piranha-external-tck-annotations-runner</artifactId>
<packaging>pom</packaging>

<name>Piranha - External - TCK - Annotations - Runner</name>

<properties>
<jimage.dir>${project.build.directory}/jimage</jimage.dir>
</properties>
<dependencies>
<dependency>
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta-annotations-tck</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>jakarta.tck</groupId>
<artifactId>sigtest-maven-plugin</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<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>
<!-- version comes from the BOM import in parent project -->
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta.annotation-api</artifactId>
<outputDirectory>${project.build.directory}</outputDirectory>
<destFileName>jakarta.annotation-api.jar</destFileName>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<executions>
<execution>
<id>sig-test</id>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
<configuration>
<dependenciesToScan>jakarta.annotation:jakarta-annotations-tck</dependenciesToScan>
<systemPropertyVariables>
<jimage.dir>${jimage.dir}</jimage.dir>
<sigTestClasspath>${project.build.directory}/jakarta.annotation-api.jar:${jimage.dir}/java.base:${jimage.dir}/java.rmi:${jimage.dir}/java.sql:${jimage.dir}/java.naming</sigTestClasspath>
<ca.sig.generated>true</ca.sig.generated>
<ca.sig.postconstruct>true</ca.sig.postconstruct>
<ca.sig.priority>true</ca.sig.priority>
<ca.sig.predestroy>true</ca.sig.predestroy>
<ca.sig.resource>true</ca.sig.resource>
<ca.sig.resources>true</ca.sig.resources>
<ca.sig.securitydeclareroles>true</ca.sig.securitydeclareroles>
<ca.sig.securitydenyall>true</ca.sig.securitydenyall>
<ca.sig.securitypermitall>true</ca.sig.securitypermitall>
<ca.sig.securityrolesallowed>true</ca.sig.securityrolesallowed>
<ca.sig.securityrunas>true</ca.sig.securityrunas>
<ca.sig.sqldatasourcedefinition>true</ca.sig.sqldatasourcedefinition>
<ca.sig.sqldatasourcedefinitions>true</ca.sig.sqldatasourcedefinitions>
</systemPropertyVariables>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
1 change: 1 addition & 0 deletions external/tck/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
<name>Piranha - External - TCK - Project</name>

<modules>
<module>annotations</module>
<module>el</module>
<module>jwt</module>
<module>server</module>
Expand Down

0 comments on commit b9b82e6

Please sign in to comment.