Description
Download the main git repositories and build them (use Java 8 as system's default or make sure JAVA_HOME points to a valid Java 8 installation)
git clone git@github.com:apache/tomee-patch-plugin.git git clone git@github.com:apache/tomee.git git clone git@github.com:apache/tomee-jakarta.git git clone git@github.com:apache/tomee-tck.git -b jakartaee9-tck for n in tomee-patch-plugin tomee tomee-jakarta; do (cd $n && mvn clean install -DskipTests -DfailIfNoTests=false) done
Ensure your ~/.m2/settings.xml file contains at least the following:
<settings> <profiles> <profile> <id>jakartaee-tck</id> <activation> <activeByDefault>true</activeByDefault> </activation> <properties> <jakartaee91.cts.home>/path/to/tcks/.</jakartaee91.cts.home> <jakartaee91.ri.home>/path/to/tcks/.</jakartaee91.ri.home> </properties> </profile> </profiles> </settings>
Set "/path/to/tcks" to any location where you would like the TCK and RI installed. Make sure the directory exists. Also ensure to add a "/." to the path when configuring it in the settings.xml.
Once this is done, there is a script that will download and setup the TCK and RI. In Ubuntu 20.04, you will need to install "libarchive-tools" as the script uses "bsdtar".
cd tomee-tck ./update91tck.sh
Now you should be all set to run a TCK test. From inside the tomee-tck project, run this command to test your setup
./runtests --ee91 -c -j --web tomee-plume com.sun.ts.tests.ejb30.bb.localaccess.statelessclient
You should see a lot of output, some SQL errors which you can ignore, and eventually some passing tests
[INFO] > JavaTest Java Version: null [INFO] > JavaTest Java Home: null [INFO] > Container Java Version: null [INFO] > Container Java Home: null =============================================================================== 1/-0/?0 - com/sun/ts/tests/ejb30/bb/localaccess/statelessclient/Client#java#exceptionTest1 - PASSED 2/-0/?0 - com/sun/ts/tests/ejb30/bb/localaccess/statelessclient/Client#java#exceptionTest2 - PASSED 3/-0/?0 - com/sun/ts/tests/ejb30/bb/localaccess/statelessclient/Client#java#exceptionTest3 - PASSED 4/-0/?0 - com/sun/ts/tests/ejb30/bb/localaccess/statelessclient/Client#java#exceptionTest4 - PASSED
For tips on debugging/fixing tests, see https://github.com/apache/tomee-tck/blob/master/DEBUGGING.adoc