Skip to content

Commit

Permalink
[Issue_183][WFLY-19397] Add a Jakarta Data TCK runner
Browse files Browse the repository at this point in the history
  • Loading branch information
bstansberry committed Sep 23, 2024
1 parent 4a88ca4 commit a82926a
Show file tree
Hide file tree
Showing 26 changed files with 3,086 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,6 @@ build.metadata
# Derby logs
derby.log
/bin/

# Jakarta Data TCK logs
*DataTCK*.log
15 changes: 15 additions & 0 deletions data/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Jakarta Data TCK Runner for Hibernate + WildFly

This project is a Jakarta Data TCK runner for Hibernate + WildFly. It is a simple project that demonstrates how to run
the Jakarta Data TCK tests against Hibernate on WildFly.

## Initialize the WildFly server
There is a install-wildfly profile that will configure a local target/wildfly install with patched org.hibernate,
jakarta.data.api and org.jboss.as.jpa modules. To use it, run:

```shell
mvn -Pstaging -Pinstall-wildfly clean process-sources
```

## Run the ValidationTests
Load the ee.jakarta.tck.data.web.validation.ValidationTests class in IntelliJ and run the tests.
216 changes: 216 additions & 0 deletions data/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,216 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
~
~ SPDX-License-Identifier: Apache-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.jboss</groupId>
<artifactId>jboss-parent</artifactId>
<version>46</version>
</parent>

<groupId>org.wildfly.data.tck</groupId>
<artifactId>data-tck-parent</artifactId>
<version>1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

<name>WildFly Jakarta Data TCK Runner Parent</name>

<properties>

<version.jakarta.data.jakarta-data-api>1.0.0</version.jakarta.data.jakarta-data-api>
<version.jakarta.data.tck>1.0.0</version.jakarta.data.tck>
<version.jakarta.enterprise>4.1.0</version.jakarta.enterprise>
<version.jakarta.servlet.jakarta-servlet-api>6.1.0</version.jakarta.servlet.jakarta-servlet-api>
<version.jakarta.validation.jakarta-validation-api>3.1.0</version.jakarta.validation.jakarta-validation-api>
<version.org.hibernate.orm>6.6.1.Final</version.org.hibernate.orm>
<version.org.jboss.arquillian.core>1.9.1.Final</version.org.jboss.arquillian.core>
<version.org.jboss.arquillian.jakarta>10.0.0.Final</version.org.jboss.arquillian.jakarta>
<version.org.jboss.logging.jboss-logging>3.6.1.Final</version.org.jboss.logging.jboss-logging>
<version.org.jboss.shrinkwrap.shrinkwrap>1.2.6</version.org.jboss.shrinkwrap.shrinkwrap>
<version.org.junit>5.10.2</version.org.junit>

<required.java.build.version>[17,)</required.java.build.version>
<jboss.home>${project.build.directory}/wildfly</jboss.home>
<wildfly.feature.pack.artifactId>wildfly-preview-feature-pack</wildfly.feature.pack.artifactId>
<embedded.server.stability>preview</embedded.server.stability>
</properties>

<!-- The Junit5 test frameworks -->
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.junit</groupId>
<artifactId>junit-bom</artifactId>
<version>${version.org.junit}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.jboss.arquillian</groupId>
<artifactId>arquillian-bom</artifactId>
<version>${version.org.jboss.arquillian.core}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.jakarta</groupId>
<artifactId>arquillian-jakarta-bom</artifactId>
<version>${version.org.jboss.arquillian.jakarta}</version>
<type>pom</type>
<scope>import</scope>
</dependency>

<!-- The API -->
<dependency>
<groupId>jakarta.data</groupId>
<artifactId>jakarta.data-api</artifactId>
<version>${version.jakarta.data.jakarta-data-api}</version>
</dependency>

<dependency>
<groupId>jakarta.servlet</groupId>
<artifactId>jakarta.servlet-api</artifactId>
<version>${version.jakarta.servlet.jakarta-servlet-api}</version>
</dependency>
<dependency>
<groupId>jakarta.enterprise</groupId>
<artifactId>jakarta.enterprise.cdi-api</artifactId>
<version>${version.jakarta.enterprise}</version>
</dependency>
<dependency>
<groupId>jakarta.validation</groupId>
<artifactId>jakarta.validation-api</artifactId>
<version>${version.jakarta.validation.jakarta-validation-api}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<version>${version.org.jboss.logging.jboss-logging}</version>
</dependency>

<dependency>
<groupId>org.jboss.shrinkwrap</groupId>
<artifactId>shrinkwrap-api</artifactId>
<version>${version.org.jboss.shrinkwrap.shrinkwrap}</version>
</dependency>

<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>hibernate-data-tck-tests</artifactId>
<version>${project.version}</version>
</dependency>

<dependency>
<groupId>jakarta.data</groupId>
<artifactId>jakarta.data-tools</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
<groupId>org.jboss.shrinkwrap</groupId>
<artifactId>shrinkwrap-api</artifactId>
</dependency>
<dependency>
<groupId>org.jboss.arquillian.junit5</groupId>
<artifactId>arquillian-junit5-core</artifactId>
</dependency>
</dependencies>

<modules>
<module>tools</module>
<module>testjar</module>
<module>wildfly-runner</module>
</modules>

<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<release>17</release>
</configuration>
</plugin>
<!-- Require Java 17+ -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>${version.enforcer.plugin}</version>
<executions>
<execution>
<id>require-java17-build</id>
<goals>
<goal>enforce</goal>
</goals>
<phase>compile</phase>
<configuration>
<rules>
<requireJavaVersion>
<version>${required.java.build.version}</version>
</requireJavaVersion>
</rules>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>

<profiles>
<!-- This profile enables consuming artifacts from the Jakarta staging repository -->
<profile>
<id>staging</id>
<activation>
<activeByDefault>false</activeByDefault>
</activation>
<repositories>
<repository>
<id>sonatype-nexus-staging</id>
<name>Sonatype Nexus Staging</name>
<url>https://jakarta.oss.sonatype.org/content/repositories/staging/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>sonatype-nexus-staging</id>
<name>Sonatype Nexus Staging</name>
<url>https://jakarta.oss.sonatype.org/content/repositories/staging/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
</project>
Loading

0 comments on commit a82926a

Please sign in to comment.