Skip to content

Commit

Permalink
Fixes piranhacloud#4241 - Add Annotations TCK for certification for P…
Browse files Browse the repository at this point in the history
…iranha Core Profile (piranhacloud#4245)
  • Loading branch information
mnriem authored Nov 23, 2024
1 parent b8dd7da commit fdcf758
Show file tree
Hide file tree
Showing 5 changed files with 238 additions and 0 deletions.
61 changes: 61 additions & 0 deletions external/coreprofile-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.coreprofiletck.annotations</groupId>
<artifactId>project</artifactId>
<version>24.12.0-SNAPSHOT</version>
</parent>

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

<name>Piranha - External - Core Profile 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/coreprofile-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.coreprofiletck</groupId>
<artifactId>project</artifactId>
<version>24.12.0-SNAPSHOT</version>
</parent>

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

<name>Piranha - External - Core Profile 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>
104 changes: 104 additions & 0 deletions external/coreprofile-tck/annotations/runner/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,104 @@
<?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.coreprofiletck.annotations</groupId>
<artifactId>project</artifactId>
<version>24.12.0-SNAPSHOT</version>
</parent>

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

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

<properties>
<jimage.dir>${project.build.directory}/jimage</jimage.dir>
</properties>
<dependencies>
<dependency>
<groupId>cloud.piranha.external.coreprofiletck.annotations</groupId>
<artifactId>piranha-external-coreprofiletck-annotations-installer</artifactId>
<version>${project.version}</version>
<type>pom</type>
</dependency>
<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>
23 changes: 23 additions & 0 deletions external/coreprofile-tck/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?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 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns:if="ant:if">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>cloud.piranha.external</groupId>
<artifactId>project</artifactId>
<version>24.12.0-SNAPSHOT</version>
</parent>
<groupId>cloud.piranha.external.coreprofiletck</groupId>
<artifactId>project</artifactId>
<packaging>pom</packaging>
<name>Piranha - External - Core Profile TCK - Project</name>
<properties>
</properties>
<modules>
<module>annotations</module>
</modules>
</project>
1 change: 1 addition & 0 deletions external/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
</dependencyManagement>

<modules>
<module>coreprofile-tck</module>
<module>ejblite</module>
<module>jakartaee-samples</module>
<module>kickoff</module>
Expand Down

0 comments on commit fdcf758

Please sign in to comment.