Skip to content

Commit

Permalink
Migrate Annotations TCK source from platform TCK project (#130)
Browse files Browse the repository at this point in the history
  • Loading branch information
alwin-joseph authored Feb 21, 2024
1 parent 292e95a commit c5f0fe1
Show file tree
Hide file tree
Showing 63 changed files with 7,816 additions and 0 deletions.
24 changes: 24 additions & 0 deletions tck-runner/README
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
//TODO: Update this file for any incomplete/incorrect information

The pom.xml in this folder can be used to run the Jakarta Annotations Standalone TCK
against Glassfish 8.0.0


Below are the instructions to run the Jakarta Annotations TCK

1. Install Java17+ , set JAVA_HOME
2. Install Maven 3.6+ set M2_HOME
3. SET PATH : add M2_HOME/bin, JAVA_HOME/bin
eg: export PATH=$ANT_HOME/bin:$M2_HOME/bin:$JAVA_HOME/bin:

4. Install the tck jar jakarta-annotations-tck-<version>.jar available inside \
jakarta-annotations-tck-<version>.zip built from jakartaee/common-annotations-api project
in this repository using below mvn install command:
`mvn install:install-file -DcreateChecksum=true -Dpackaging=jar
-Dfile=jakarta-annotations-tck-<version>.jar -DgroupId=jakarta.3tck
-DartifactId=jakarta-annotations-tck -Dversion=<version>`


5. Use the sample tck-runner/pom.xml available in jakartaee/common-annotations-api project,
to run the test with Glassfish, verify the system properties set.
Run `mvn clean verify` from the current directory.
194 changes: 194 additions & 0 deletions tck-runner/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,194 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
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 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>jakarta</groupId>
<artifactId>glassfish.annotations-tck</artifactId>
<version>11.0.0</version>
<packaging>jar</packaging>

<properties>
<glassfish.container.version>8.0.0-M1</glassfish.container.version>
<glassfish.toplevel.dir>glassfish7</glassfish.toplevel.dir>
<junit.jupiter.version>5.9.1</junit.jupiter.version>
<tck.artifactId>jakarta-annotations-tck</tck.artifactId>
<tck.version>3.0.0</tck.version>
</properties>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.junit</groupId>
<artifactId>junit-bom</artifactId>
<version>${junit.jupiter.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<version>${junit.jupiter.version}</version>
</dependency>
<dependency>
<groupId>jakarta.tck</groupId>
<artifactId>${tck.artifactId}</artifactId>
<version>${tck.version}</version>
</dependency>
<dependency>
<groupId>jakarta.tck</groupId>
<artifactId>sigtest-maven-plugin</artifactId>
<version>2.1</version>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.2.0</version>
<executions>
<execution>
<id>unpack</id>
<goals>
<goal>unpack</goal>
</goals>
<phase>generate-resources</phase>
<configuration>
<artifactItems>
<artifactItem>
<groupId>jakartatck</groupId>
<artifactId>${tck.artifactId}</artifactId>
<version>${tck.version}</version>
<type>zip</type>
<overWrite>true</overWrite>
<outputDirectory>${project.build.directory}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.2.0</version>
<executions>
<execution>
<id>unpack</id>
<goals>
<goal>unpack</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<artifactItems>
<artifactItem>
<groupId>org.glassfish.main.distributions</groupId>
<artifactId>${glassfish-artifact-id}</artifactId>
<version>${glassfish.container.version}</version>
<type>zip</type>
<overWrite>true</overWrite>
<outputDirectory>${project.build.directory}</outputDirectory>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>

<!-- <plugin>
<groupId>org.netbeans.tools</groupId>
<artifactId>sigtest-maven-plugin</artifactId>
<version>1.5</version>
<configuration>
<sigfile>target/annotations-tck/jakarta.annotation.sig</sigfile>
<packages>jakarta.annotation,jakarta.annotation.security,jakarta.annotation.sql,akarta.annotation.Generated,jakarta.annotation.ManagedBean,jakarta.annotation.PostConstruct,jakarta.annotation.PreDestroy,jakarta.annotation.Priority,jakarta.annotation.Resource,jakarta.annotation.Resource$AuthenticationType,jakarta.annotation.Resources,jakarta.annotation.security.DeclareRoles,jakarta.annotation.security.DenyAll,jakarta.annotation.security.PermitAll,jakarta.annotation.security.RolesAllowed,jakarta.annotation.security.RunAs,jakarta.annotation.sql.DataSourceDefinition,jakarta.annotation.sql.DataSourceDefinitions</packages>
<classes>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/modules/jakarta.annotation-api.jar</classes>
<report>target/sig-report.txt</report>
</configuration>
<executions>
<execution>
<id>sigtest</id>
<goals>
<goal>check</goal>
</goals>
<phase>verify</phase>
</execution>
</executions>
</plugin> -->

<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<version>3.0.0-M5</version>
<executions>
<execution>
<id>sig-test</id>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
<configuration>
<dependenciesToScan>jakarta.tck:${tck.artifactId}</dependenciesToScan>
<systemPropertyVariables>
<jimage.dir>${project.build.directory}/jdk11-bundle</jimage.dir>
<sigTestClasspath>${project.build.directory}/${glassfish.toplevel.dir}/glassfish/modules/jakarta.annotation-api.jar:${project.build.directory}/jdk11-bundle/java.base:${project.build.directory}/jdk11-bundle/java.rmi:${project.build.directory}/jdk11-bundle/java.sql:${project.build.directory}/jdk11-bundle/java.naming</sigTestClasspath>
<ca.sig.generated>true</ca.sig.generated>
<ca.sig.managedbean>false</ca.sig.managedbean>
<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>

<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>
73 changes: 73 additions & 0 deletions tck/docs/CAJ2.1-ReleaseNotes.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=windows-1252">
<title>Jakarta Annotations TCK, Version 2.1 Release Notes, December 2021</title>
<!--
Copyright (c) 2018, 2021 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-->
<style type="text/css">
<!--
body { background-color: #ffffdd; color: #000000}
pre { background-color: #eeeeee; color: #000099; font-size: smaller}
code { color: #000099; font-size: smaller}
h1 { color: #000099}
h2 { color: #000099}
h3 { color: #000099; text-decoration: underline}
h4 { font-style: italic; color: #000099}
.tabletitle { font-style: italic; color: #ffffcc; font-size: small; font-variant: small-caps}
.subtitle { font-style: italic; color: #ffffcc; font-variant: small-caps}
.emphasize { font-style: italic; color: #000099}
.step { font-weight: bold}
.note { background-color: #fffff0; border-bottom-width: thin; border-top-width: thin; border-top-style: inset; border-bottom-style: inset; font-size: -10%;}
th { background-color: #eeeeee; padding-left: 2pt; padding-right: 2pt;}
-->
</style></head>
<body>
<div align="center">
<h1>Jakarta Annotations Technology Compatibility Kit, Version 2.1<br>
<em class="emphasize">Release Notes, December 2021</em></h1>
</div>
<h2><a name="kit_contents">Kit Contents</a></h2>
<p>The Jakarta Annotations, Version 2.1 Technology Compatibility Kit (TCK)
includes the following items:</p>
<ul>
<li>
<p><strong>Jakarta Annotations TCK Signature Tests:</strong> Check that
all public APIs are supported and/or defined as specified in the
Jakarta Annotations specification, Version 2.1 implementation under
test.</p>
</li>
</ul>
<hr>
<h2><a name="platform">Platform Notes</a></h2>
<p>The Jakarta Annotations TCK tests have been built with JDK 11 and tested
with OpenJDK 11 and OpenJDK 17.</p>
<p>The Jakarta Annotations TCK tests have been run on the following
platforms:</p>
<ul>
<li>Debian Linux 10</li>
</ul>
<p>The Jakarta Annotations TCK tests have been run against the following
Common Annotations for Jakarta EE compatible implementations:</p>
<ul>
<li>Jakarta Annotations for Java Compatible Implementation Version 2.1</li>
</ul>
<hr>
<h2><a name="install_setup_run">Installing, Setting Up, and Running the
Jakarta Annotations TCK</a></h2>
<p>Refer to the <cite>Jakarta Annotations for Jakarta EE TCK 2.1 User's
Guide</cite> for complete instructions on installing, setting up, and
running the Jakarta Annotations TCK. The online version of the JT Harness
version 5.0 documentation is available <a href="https://wiki.openjdk.java.net/display/CodeTools/Documentation">here</a>.</p>
<hr>
<p><cite><small></small></cite></p>
<address><small> Copyright © 2013, 2021 Oracle and/or its affiliates. All
rights reserved. </small></address>
<cite>
<p></p>
</cite>
</body>
</html>
72 changes: 72 additions & 0 deletions tck/docs/CAJ3.0-ReleaseNotes.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=windows-1252">
<title>Jakarta Annotations TCK, Version 2.1 Release Notes, December 2021</title>
<!--
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-->
<style type="text/css">
<!--
body { background-color: #ffffdd; color: #000000}
pre { background-color: #eeeeee; color: #000099; font-size: smaller}
code { color: #000099; font-size: smaller}
h1 { color: #000099}
h2 { color: #000099}
h3 { color: #000099; text-decoration: underline}
h4 { font-style: italic; color: #000099}
.tabletitle { font-style: italic; color: #ffffcc; font-size: small; font-variant: small-caps}
.subtitle { font-style: italic; color: #ffffcc; font-variant: small-caps}
.emphasize { font-style: italic; color: #000099}
.step { font-weight: bold}
.note { background-color: #fffff0; border-bottom-width: thin; border-top-width: thin; border-top-style: inset; border-bottom-style: inset; font-size: -10%;}
th { background-color: #eeeeee; padding-left: 2pt; padding-right: 2pt;}
-->
</style></head>
<body>
<div align="center">
<h1>Jakarta Annotations Technology Compatibility Kit, Version 3.0<br>
<em class="emphasize">Release Notes, February 2024</em></h1>
</div>
<h2><a name="kit_contents">Kit Contents</a></h2>
<p>The Jakarta Annotations, Version 3.0 Technology Compatibility Kit (TCK)
includes the following items:</p>
<ul>
<li>
<p><strong>Jakarta Annotations TCK Signature Tests:</strong> Check that
all public APIs are supported and/or defined as specified in the
Jakarta Annotations specification, Version 3.0 implementation under
test.</p>
</li>
</ul>
<hr>
<h2><a name="platform">Platform Notes</a></h2>
<p>The Jakarta Annotations TCK tests have been built with JDK 17 and tested
with OpenJDK 17</p>
<p>The Jakarta Annotations TCK tests have been run on the following
platforms:</p>
<ul>
<li>Debian Linux 10</li>
</ul>
<p>The Jakarta Annotations TCK tests have been run against the following
Common Annotations for Jakarta EE compatible implementations:</p>
<ul>
<li>Jakarta Annotations for Java Compatible Implementation Version 3.0</li>
</ul>
<hr>
<h2><a name="install_setup_run">Installing, Setting Up, and Running the
Jakarta Annotations TCK</a></h2>
<p>Refer to the <cite>Jakarta Annotations for Jakarta EE TCK 3.0 User's
Guide</cite> for complete instructions on installing, setting up, and
running the Jakarta Annotations TCK.
<hr>
<p><cite><small></small></cite></p>
<address><small> Copyright (c) 2013, 2024 Oracle and/or its affiliates. All
rights reserved. </small></address>
<cite>
<p></p>
</cite>
</body>
</html>
Loading

0 comments on commit c5f0fe1

Please sign in to comment.