deltaspike-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t...@apache.org
Subject git commit: DELTASPIKE-589 WLS deployment as EAR, including DataSource
Date Thu, 15 May 2014 13:10:33 GMT
Repository: deltaspike
Updated Branches:
  refs/heads/master 1a43da803 -> 59f8c0cd5


DELTASPIKE-589 WLS deployment as EAR, including DataSource


Project: http://git-wip-us.apache.org/repos/asf/deltaspike/repo
Commit: http://git-wip-us.apache.org/repos/asf/deltaspike/commit/59f8c0cd
Tree: http://git-wip-us.apache.org/repos/asf/deltaspike/tree/59f8c0cd
Diff: http://git-wip-us.apache.org/repos/asf/deltaspike/diff/59f8c0cd

Branch: refs/heads/master
Commit: 59f8c0cd5fa4225cfc531d003053a856be126e3c
Parents: 1a43da8
Author: Thomas Hug <Thomas.Hug@ctp.com>
Authored: Thu May 15 15:04:05 2014 +0200
Committer: Thomas Hug <Thomas.Hug@ctp.com>
Committed: Thu May 15 15:10:06 2014 +0200

----------------------------------------------------------------------
 .../deltaspike/data/impl/QueryResultTest.java   | 10 ++--
 .../data/impl/RepositoryExtensionTest.java      | 14 +++---
 .../impl/audit/AuditEntityListenerTest.java     | 10 ++--
 .../data/impl/criteria/CriteriaTest.java        | 10 ++--
 .../data/impl/handler/EntityManagerTest.java    | 16 ++++---
 .../handler/EntityRepositoryHandlerTest.java    | 10 ++--
 .../data/impl/handler/QueryHandlerTest.java     | 10 ++--
 .../data/impl/mapping/MappedRepositoryTest.java | 20 ++++----
 .../meta/unit/OrmXmlBasedRepositoryTest.java    |  8 ++--
 .../data/impl/spi/CdiQuerySpiTest.java          | 14 +++---
 .../impl/tx/TransactionalQueryRunnerTest.java   | 10 ++--
 .../jpa/QueryStringExtractorFactoryTest.java    |  3 +-
 .../data/test/util/TestDeployments.java         | 35 ++++++++++++--
 .../src/test/resources-weblogic/TestDS-jdbc.xml | 49 ++++++++++++++++++++
 .../test-mapped-persistence.xml                 |  7 +--
 .../resources-weblogic/test-persistence.xml     |  5 +-
 .../resources-weblogic/weblogic-application.xml | 26 +++++++++++
 deltaspike/parent/code/pom.xml                  |  3 +-
 18 files changed, 190 insertions(+), 70 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/QueryResultTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/QueryResultTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/QueryResultTest.java
index 5e13512..5efec2d 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/QueryResultTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/QueryResultTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertNotNull;
@@ -41,7 +43,6 @@ import org.apache.deltaspike.data.test.domain.Simple;
 import org.apache.deltaspike.data.test.domain.SimpleBuilder;
 import org.apache.deltaspike.data.test.domain.Simple_;
 import org.apache.deltaspike.data.test.service.SimpleRepository;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.shrinkwrap.api.Archive;
@@ -56,9 +57,10 @@ public class QueryResultTest extends TransactionalTestCase
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments.initDeployment()
-                .addClasses(SimpleRepository.class)
-                .addPackage(Simple.class.getPackage());
+        return finalizeDeployment(QueryResultTest.class,
+                initDeployment()
+                    .addClasses(SimpleRepository.class)
+                    .addPackage(Simple.class.getPackage()));
     }
 
     @Inject

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/RepositoryExtensionTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/RepositoryExtensionTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/RepositoryExtensionTest.java
index d4328e7..ffa48bb 100755
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/RepositoryExtensionTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/RepositoryExtensionTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertNotNull;
 
 import javax.enterprise.inject.Instance;
@@ -27,7 +29,6 @@ import org.apache.deltaspike.data.test.domain.Simple;
 import org.apache.deltaspike.data.test.service.ExtendedRepositoryInterface;
 import org.apache.deltaspike.data.test.service.RepositoryInterface;
 import org.apache.deltaspike.data.test.service.SimpleRepository;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.arquillian.junit.Arquillian;
@@ -44,11 +45,12 @@ public class RepositoryExtensionTest
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments.initDeployment()
-                .addClasses(RepositoryInterface.class,
-                            ExtendedRepositoryInterface.class,
-                            SimpleRepository.class)
-                .addPackages(true, Simple.class.getPackage());
+        return finalizeDeployment(RepositoryExtensionTest.class,
+                initDeployment()
+                    .addClasses(RepositoryInterface.class,
+                                ExtendedRepositoryInterface.class,
+                                SimpleRepository.class)
+                    .addPackages(true, Simple.class.getPackage()));
     }
 
     @Inject

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/audit/AuditEntityListenerTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/audit/AuditEntityListenerTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/audit/AuditEntityListenerTest.java
index 3b9efe2..fa84a77 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/audit/AuditEntityListenerTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/audit/AuditEntityListenerTest.java
@@ -18,6 +18,7 @@
  */
 package org.apache.deltaspike.data.impl.audit;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
 import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertNotNull;
@@ -44,10 +45,11 @@ public class AuditEntityListenerTest extends TransactionalTestCase
     @Deployment
     public static Archive<?> deployment()
     {
-        return initDeployment()
-                .addPackage(AuditEntityListener.class.getPackage())
-                .addAsWebInfResource("test-orm.xml", ArchivePaths.create("classes/META-INF/orm.xml"))
-                .addPackage(AuditedEntity.class.getPackage());
+        return finalizeDeployment(AuditEntityListenerTest.class,
+                initDeployment()
+                    .addPackage(AuditEntityListener.class.getPackage())
+                    .addAsWebInfResource("test-orm.xml", ArchivePaths.create("classes/META-INF/orm.xml"))
+                    .addPackage(AuditedEntity.class.getPackage()));
     }
 
     @PersistenceContext

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/criteria/CriteriaTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/criteria/CriteriaTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/criteria/CriteriaTest.java
index 06a4d2d..931f42c 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/criteria/CriteriaTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/criteria/CriteriaTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl.criteria;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertNotNull;
 import static org.junit.Assert.assertNull;
@@ -39,7 +41,6 @@ import org.apache.deltaspike.data.test.domain.Simple;
 import org.apache.deltaspike.data.test.service.ParentRepository;
 import org.apache.deltaspike.data.test.service.SimpleCriteriaRepository;
 import org.apache.deltaspike.data.test.service.Statistics;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.shrinkwrap.api.Archive;
@@ -53,9 +54,10 @@ public class CriteriaTest extends TransactionalTestCase
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments.initDeployment()
-                .addClasses(SimpleCriteriaRepository.class, ParentRepository.class, Statistics.class)
-                .addPackage(Simple.class.getPackage());
+        return finalizeDeployment(CriteriaTest.class,
+                initDeployment()
+                    .addClasses(SimpleCriteriaRepository.class, ParentRepository.class, Statistics.class)
+                    .addPackage(Simple.class.getPackage()));
     }
 
     @Inject

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityManagerTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityManagerTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityManagerTest.java
index b49ae13..fb29f46 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityManagerTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityManagerTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl.handler;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertNotNull;
 import static org.junit.Assert.fail;
@@ -32,7 +34,6 @@ import org.apache.deltaspike.data.test.service.SimpleRepositoryWithEntityManager
 import org.apache.deltaspike.data.test.service.SimpleRepositoryWithEntityManagerResolver;
 import org.apache.deltaspike.data.test.service.Simplistic;
 import org.apache.deltaspike.data.test.service.SimplisticEntityManagerResolver;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.arquillian.junit.Arquillian;
@@ -49,12 +50,13 @@ public class EntityManagerTest
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments.initDeployment()
-                .addClasses(SimpleRepositoryWithEntityManager.class,
-                        SimpleRepositoryWithEntityManagerResolver.class,
-                        QualifiedEntityManagerTestProducer.class,
-                        NonQualifiedEntityManagerTestProducer.class,
-                        Simplistic.class, SimplisticEntityManagerResolver.class);
+        return finalizeDeployment(EntityManagerTest.class,
+                initDeployment()
+                    .addClasses(SimpleRepositoryWithEntityManager.class,
+                            SimpleRepositoryWithEntityManagerResolver.class,
+                            QualifiedEntityManagerTestProducer.class,
+                            NonQualifiedEntityManagerTestProducer.class,
+                            Simplistic.class, SimplisticEntityManagerResolver.class));
     }
 
     @Inject

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityRepositoryHandlerTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityRepositoryHandlerTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityRepositoryHandlerTest.java
index 0b45822..5f5d2a2 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityRepositoryHandlerTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/EntityRepositoryHandlerTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl.handler;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertNotNull;
@@ -35,7 +37,6 @@ import org.apache.deltaspike.data.test.TransactionalTestCase;
 import org.apache.deltaspike.data.test.domain.Simple;
 import org.apache.deltaspike.data.test.domain.Simple_;
 import org.apache.deltaspike.data.test.service.ExtendedRepositoryInterface;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.shrinkwrap.api.Archive;
@@ -49,9 +50,10 @@ public class EntityRepositoryHandlerTest extends TransactionalTestCase
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments.initDeployment()
-                .addClasses(ExtendedRepositoryInterface.class)
-                .addPackage(Simple.class.getPackage());
+        return finalizeDeployment(EntityRepositoryHandlerTest.class,
+                initDeployment()
+                    .addClasses(ExtendedRepositoryInterface.class)
+                    .addPackage(Simple.class.getPackage()));
     }
 
     @Inject

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/QueryHandlerTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/QueryHandlerTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/QueryHandlerTest.java
index 4904fda..9be3d02 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/QueryHandlerTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/handler/QueryHandlerTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl.handler;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertNotNull;
@@ -38,7 +40,6 @@ import org.apache.deltaspike.data.test.domain.Simple2;
 import org.apache.deltaspike.data.test.domain.SimpleBuilder;
 import org.apache.deltaspike.data.test.service.Simple2Repository;
 import org.apache.deltaspike.data.test.service.SimpleRepository;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.shrinkwrap.api.Archive;
@@ -53,9 +54,10 @@ public class QueryHandlerTest extends TransactionalTestCase
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments.initDeployment()
-                .addClasses(SimpleRepository.class, Simple2Repository.class)
-                .addPackage(Simple.class.getPackage());
+        return finalizeDeployment(QueryHandlerTest.class,
+                initDeployment()
+                    .addClasses(SimpleRepository.class, Simple2Repository.class)
+                    .addPackage(Simple.class.getPackage()));
     }
 
     @Inject

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/mapping/MappedRepositoryTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/mapping/MappedRepositoryTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/mapping/MappedRepositoryTest.java
index 38345f9..ff9db51 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/mapping/MappedRepositoryTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/mapping/MappedRepositoryTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl.mapping;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertNotNull;
 import static org.junit.Assert.assertTrue;
@@ -37,7 +39,6 @@ import org.apache.deltaspike.data.test.domain.dto.SimpleDto;
 import org.apache.deltaspike.data.test.service.SimpleMappedRepository;
 import org.apache.deltaspike.data.test.service.SimpleMapper;
 import org.apache.deltaspike.data.test.service.WrappedMapper;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.shrinkwrap.api.Archive;
@@ -51,14 +52,15 @@ public class MappedRepositoryTest extends TransactionalTestCase
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments.initDeployment()
-                .addClasses(
-                        SimpleMappedRepository.class,
-                        SimpleMapper.class,
-                        WrappedMapper.class)
-                .addPackages(false,
-                        Simple.class.getPackage(),
-                        SimpleDto.class.getPackage());
+        return finalizeDeployment(MappedRepositoryTest.class,
+                initDeployment()
+                    .addClasses(
+                            SimpleMappedRepository.class,
+                            SimpleMapper.class,
+                            WrappedMapper.class)
+                    .addPackages(false,
+                            Simple.class.getPackage(),
+                            SimpleDto.class.getPackage()));
     }
 
     @Inject

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/meta/unit/OrmXmlBasedRepositoryTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/meta/unit/OrmXmlBasedRepositoryTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/meta/unit/OrmXmlBasedRepositoryTest.java
index 20e1568..959764a 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/meta/unit/OrmXmlBasedRepositoryTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/meta/unit/OrmXmlBasedRepositoryTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl.meta.unit;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertEquals;
 
 import javax.enterprise.inject.Produces;
@@ -28,7 +30,6 @@ import javax.persistence.PersistenceContext;
 import org.apache.deltaspike.data.test.TransactionalTestCase;
 import org.apache.deltaspike.data.test.domain.mapped.MappedOne;
 import org.apache.deltaspike.data.test.service.MappedOneRepository;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.shrinkwrap.api.Archive;
@@ -45,8 +46,7 @@ public class OrmXmlBasedRepositoryTest extends TransactionalTestCase
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments
-                .initDeployment("(.*mapped.*)|(.*test.*)")
+        return finalizeDeployment(OrmXmlBasedRepositoryTest.class, initDeployment("(.*mapped.*)|(.*test.*)")
                 .addClasses(MappedOneRepository.class)
                 .addAsLibraries(
                         ShrinkWrap.create(JavaArchive.class, "domain.jar")
@@ -55,7 +55,7 @@ public class OrmXmlBasedRepositoryTest extends TransactionalTestCase
                 )
                 .addAsWebInfResource("test-mapped-persistence.xml",
                         ArchivePaths.create("classes/META-INF/persistence.xml"))
-                .addAsWebInfResource("test-default-orm.xml", ArchivePaths.create("classes/META-INF/orm.xml"));
+                .addAsWebInfResource("test-default-orm.xml", ArchivePaths.create("classes/META-INF/orm.xml")));
     }
 
     @Produces

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/spi/CdiQuerySpiTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/spi/CdiQuerySpiTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/spi/CdiQuerySpiTest.java
index 32e9703..f551bf4 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/spi/CdiQuerySpiTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/spi/CdiQuerySpiTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl.spi;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertNotNull;
 
 import javax.enterprise.inject.Produces;
@@ -30,7 +32,6 @@ import org.apache.deltaspike.data.test.domain.Simple;
 import org.apache.deltaspike.data.test.service.MyEntityRepository;
 import org.apache.deltaspike.data.test.service.MyEntityRepositoryDelegate;
 import org.apache.deltaspike.data.test.service.MySimpleRepository;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.shrinkwrap.api.Archive;
@@ -44,11 +45,12 @@ public class CdiQuerySpiTest extends TransactionalTestCase
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments.initDeployment()
-                .addClasses(MySimpleRepository.class,
-                        MyEntityRepository.class,
-                        MyEntityRepositoryDelegate.class)
-                .addPackage(Simple.class.getPackage());
+        return finalizeDeployment(CdiQuerySpiTest.class,
+                initDeployment()
+                    .addClasses(MySimpleRepository.class,
+                            MyEntityRepository.class,
+                            MyEntityRepositoryDelegate.class)
+                    .addPackage(Simple.class.getPackage()));
     }
 
     @Produces

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/tx/TransactionalQueryRunnerTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/tx/TransactionalQueryRunnerTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/tx/TransactionalQueryRunnerTest.java
index 98d6878..0504cfa 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/tx/TransactionalQueryRunnerTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/tx/TransactionalQueryRunnerTest.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.impl.tx;
 
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
+import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertNotNull;
 import static org.junit.Assert.assertTrue;
 
@@ -28,7 +30,6 @@ import javax.persistence.PersistenceContext;
 
 import org.apache.deltaspike.data.test.domain.Simple;
 import org.apache.deltaspike.data.test.service.ExtendedRepositoryInterface;
-import org.apache.deltaspike.data.test.util.TestDeployments;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.jboss.arquillian.container.test.api.Deployment;
 import org.jboss.arquillian.junit.Arquillian;
@@ -49,9 +50,10 @@ public class TransactionalQueryRunnerTest
     @Deployment
     public static Archive<?> deployment()
     {
-        return TestDeployments.initDeployment()
-                .addClasses(ExtendedRepositoryInterface.class)
-                .addPackage(Simple.class.getPackage());
+        return finalizeDeployment(TransactionalQueryRunnerTest.class,
+                initDeployment()
+                    .addClasses(ExtendedRepositoryInterface.class)
+                    .addPackage(Simple.class.getPackage()));
     }
 
     @Inject

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/util/jpa/QueryStringExtractorFactoryTest.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/util/jpa/QueryStringExtractorFactoryTest.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/util/jpa/QueryStringExtractorFactoryTest.java
index 0c2e4f3..26379a7 100644
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/util/jpa/QueryStringExtractorFactoryTest.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/impl/util/jpa/QueryStringExtractorFactoryTest.java
@@ -20,6 +20,7 @@ package org.apache.deltaspike.data.impl.util.jpa;
 
 import static java.lang.Thread.currentThread;
 import static java.lang.reflect.Proxy.newProxyInstance;
+import static org.apache.deltaspike.data.test.util.TestDeployments.finalizeDeployment;
 import static org.apache.deltaspike.data.test.util.TestDeployments.initDeployment;
 import static org.junit.Assert.assertEquals;
 
@@ -52,7 +53,7 @@ public class QueryStringExtractorFactoryTest
     @Deployment
     public static Archive<?> deployment()
     {
-        return initDeployment();
+        return finalizeDeployment(QueryStringExtractorFactoryTest.class, initDeployment());
     }
 
     @Test

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/test/util/TestDeployments.java
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/test/util/TestDeployments.java
b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/test/util/TestDeployments.java
index 0472a40..98ee9e3 100755
--- a/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/test/util/TestDeployments.java
+++ b/deltaspike/modules/data/impl/src/test/java/org/apache/deltaspike/data/test/util/TestDeployments.java
@@ -18,6 +18,8 @@
  */
 package org.apache.deltaspike.data.test.util;
 
+import java.net.URL;
+
 import org.apache.deltaspike.data.api.AbstractEntityRepository;
 import org.apache.deltaspike.data.api.EntityManagerConfig;
 import org.apache.deltaspike.data.api.EntityManagerResolver;
@@ -59,12 +61,14 @@ import org.apache.deltaspike.data.test.domain.AuditedEntity;
 import org.apache.deltaspike.jpa.impl.transaction.EnvironmentAwareTransactionStrategy;
 import org.apache.deltaspike.test.category.WebProfileCategory;
 import org.apache.deltaspike.test.utils.CdiContainerUnderTest;
+import org.jboss.arquillian.container.test.spi.TestDeployment;
 import org.jboss.shrinkwrap.api.Archive;
 import org.jboss.shrinkwrap.api.ArchivePath;
 import org.jboss.shrinkwrap.api.ArchivePaths;
 import org.jboss.shrinkwrap.api.Filter;
 import org.jboss.shrinkwrap.api.ShrinkWrap;
 import org.jboss.shrinkwrap.api.asset.StringAsset;
+import org.jboss.shrinkwrap.api.spec.EnterpriseArchive;
 import org.jboss.shrinkwrap.api.spec.JavaArchive;
 import org.jboss.shrinkwrap.api.spec.WebArchive;
 import org.jboss.shrinkwrap.descriptor.api.Descriptors;
@@ -99,9 +103,8 @@ public abstract class TestDeployments
         WebArchive archive = ShrinkWrap
                 .create(WebArchive.class, "test.war")
                 .addAsLibrary(createApiArchive())
-                .addClass(WebProfileCategory.class)
+                .addClasses(WebProfileCategory.class, TransactionalTestCase.class)
                 .addClasses(RepositoryExtension.class, RepositoryDefinitionException.class)
-                .addClasses(TransactionalTestCase.class)
                 .addPackages(true, TEST_FILTER, createImplPackages())
                 .addPackages(true, AuditedEntity.class.getPackage())
                 .addPackages(true, new ExcludeRegExpPaths(testFilter), TransactionalTestCase.class.getPackage())
@@ -110,10 +113,27 @@ public abstract class TestDeployments
                 .addAsWebInfResource("META-INF/services/javax.enterprise.inject.spi.Extension",
                         ArchivePaths.create("classes/META-INF/services/javax.enterprise.inject.spi.Extension"))
                 .addAsWebInfResource(new StringAsset(descriptor), ArchivePaths.create("beans.xml"));
-
         return addDependencies(archive);
     }
 
+    public static Archive<?> finalizeDeployment(Class<?> testClass, WebArchive
archive)
+    {
+        if (CdiContainerUnderTest.is("wls-.*"))
+        {
+            archive.addClass(testClass); // see https://issues.jboss.org/browse/ARQ-659
+            EnterpriseArchive ear = ShrinkWrap.create(EnterpriseArchive.class, "test.ear")
+                    .addAsModule(archive);
+            ear.addAsLibraries(Maven.resolver()
+                    .resolve("hsqldb:hsqldb:1.8.0.10")
+                    .withTransitivity()
+                    .asFile());
+            addToEarManifestIfExists(ear, "weblogic-application.xml");
+            addToEarManifestIfExists(ear, "TestDS-jdbc.xml");
+            return ear;
+        }
+        return archive;
+    }
+
     public static Package[] createImplPackages()
     {
         return new Package[] {
@@ -182,4 +202,13 @@ public abstract class TestDeployments
         return webArchive;
     }
 
+    public static void addToEarManifestIfExists(EnterpriseArchive archive, String resource)
+    {
+        URL url = TestDeployment.class.getClassLoader().getResource(resource);
+        if (url != null) {
+            archive.addAsManifestResource(resource);
+        }
+    }
+
+
 }

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/resources-weblogic/TestDS-jdbc.xml
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/resources-weblogic/TestDS-jdbc.xml b/deltaspike/modules/data/impl/src/test/resources-weblogic/TestDS-jdbc.xml
new file mode 100644
index 0000000..9cfb3e6
--- /dev/null
+++ b/deltaspike/modules/data/impl/src/test/resources-weblogic/TestDS-jdbc.xml
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you 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.
+-->
+<jdbc-data-source xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.bea.com/ns/weblogic/weblogic-jdbc.xsd"
+    xmlns="http://www.bea.com/ns/weblogic/jdbc-data-source">
+    <name>TestDS</name>
+    <jdbc-driver-params>
+        <url>jdbc:hsqldb:.</url>
+        <driver-name>org.hsqldb.jdbcDriver</driver-name>
+        <properties>
+            <property>
+                <name>user</name>
+                <value>sa</value>
+            </property>
+            <property>
+                <name>password</name>
+                <value></value>
+            </property>
+        </properties>
+    </jdbc-driver-params>
+
+    <jdbc-connection-pool-params>
+        <initial-capacity>2</initial-capacity>
+        <max-capacity>10</max-capacity>
+        <test-connections-on-reserve>false</test-connections-on-reserve>
+    </jdbc-connection-pool-params>
+
+    <jdbc-data-source-params>
+        <jndi-name>TestDS</jndi-name>
+        <scope>Application</scope>
+        <global-transactions-protocol>TwoPhaseCommit</global-transactions-protocol>
+    </jdbc-data-source-params>
+</jdbc-data-source>

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/resources-weblogic/test-mapped-persistence.xml
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/resources-weblogic/test-mapped-persistence.xml
b/deltaspike/modules/data/impl/src/test/resources-weblogic/test-mapped-persistence.xml
index 6828961..78bc349 100644
--- a/deltaspike/modules/data/impl/src/test/resources-weblogic/test-mapped-persistence.xml
+++ b/deltaspike/modules/data/impl/src/test/resources-weblogic/test-mapped-persistence.xml
@@ -20,16 +20,13 @@
 <persistence version="2.0" xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd">
     <persistence-unit name="test"> 
         <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
+        <jta-data-source>java:/app/jdbc/TestDS</jta-data-source>
         <mapping-file>META-INF/orm.xml</mapping-file>
         <mapping-file>META-INF/custom-orm.xml</mapping-file>
         <properties>
             <property name="eclipselink.ddl-generation" value="drop-and-create-tables"/>
             <property name="eclipselink.logging.level" value="FINE"/>
-            <property name="eclipselink.logging.parameters" value="true" />
-            <property name="javax.persistence.jdbc.driver" value="org.hsqldb.jdbcDriver"/>
 
-            <property name="javax.persistence.jdbc.url" value="jdbc:hsqldb:."/>  
-            <property name="javax.persistence.jdbc.user" value="sa"/>  
-            <property name="javax.persistence.jdbc.password" value=""/>  
+            <property name="eclipselink.logging.parameters" value="true" /> 
         </properties>
     </persistence-unit>
 </persistence>

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/resources-weblogic/test-persistence.xml
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/resources-weblogic/test-persistence.xml
b/deltaspike/modules/data/impl/src/test/resources-weblogic/test-persistence.xml
index 3fd1174..beef4f2 100644
--- a/deltaspike/modules/data/impl/src/test/resources-weblogic/test-persistence.xml
+++ b/deltaspike/modules/data/impl/src/test/resources-weblogic/test-persistence.xml
@@ -20,14 +20,11 @@
 <persistence version="2.0" xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd">
     <persistence-unit name="test"> 
         <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
+        <jta-data-source>java:/app/jdbc/TestDS</jta-data-source>
         <properties>
             <property name="eclipselink.ddl-generation" value="drop-and-create-tables"/>
             <property name="eclipselink.logging.level" value="FINE"/>
             <property name="eclipselink.logging.parameters" value="true" />
-            <property name="javax.persistence.jdbc.driver" value="org.hsqldb.jdbcDriver"/>
 
-            <property name="javax.persistence.jdbc.url" value="jdbc:hsqldb:."/>  
-            <property name="javax.persistence.jdbc.user" value="sa"/>  
-            <property name="javax.persistence.jdbc.password" value=""/>  
         </properties>
     </persistence-unit>
 </persistence>

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/modules/data/impl/src/test/resources-weblogic/weblogic-application.xml
----------------------------------------------------------------------
diff --git a/deltaspike/modules/data/impl/src/test/resources-weblogic/weblogic-application.xml
b/deltaspike/modules/data/impl/src/test/resources-weblogic/weblogic-application.xml
new file mode 100644
index 0000000..9c9328b
--- /dev/null
+++ b/deltaspike/modules/data/impl/src/test/resources-weblogic/weblogic-application.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one
+    or more contributor license agreements.  See the NOTICE file
+    distributed with this work for additional information
+    regarding copyright ownership.  The ASF licenses this file
+    to you 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.
+-->
+<wls:weblogic-application xmlns:wls="http://xmlns.oracle.com/weblogic/weblogic-application"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/javaee_5.xsd http://xmlns.oracle.com/weblogic/weblogic-application
http://xmlns.oracle.com/weblogic/weblogic-application/1.4/weblogic-application.xsd">
+    <wls:module>
+        <wls:name>TestDS</wls:name>
+        <wls:type>JDBC</wls:type>
+        <wls:path>META-INF/TestDS-jdbc.xml</wls:path>
+    </wls:module>
+</wls:weblogic-application>

http://git-wip-us.apache.org/repos/asf/deltaspike/blob/59f8c0cd/deltaspike/parent/code/pom.xml
----------------------------------------------------------------------
diff --git a/deltaspike/parent/code/pom.xml b/deltaspike/parent/code/pom.xml
index 1a8ae08..4a2a998 100644
--- a/deltaspike/parent/code/pom.xml
+++ b/deltaspike/parent/code/pom.xml
@@ -40,6 +40,7 @@
         <wildfly.version>8.0.0.Final</wildfly.version>
         <glassfish3.version>3.1.2.2</glassfish3.version>
         <glassfish4.version>4.0</glassfish4.version>
+        <wls.version>12.1</wls.version>
     </properties>
 
 
@@ -951,7 +952,7 @@
             <id>wls-remote-12c</id>
 
             <properties>
-                <cdicontainer.version>weld-${weld.version}</cdicontainer.version>
+                <cdicontainer.version>wls-${wls.version}</cdicontainer.version>
             </properties>
 
             <dependencies>


Mime
View raw message