Author: cschneider
Date: Fri Jul 17 11:00:50 2015
New Revision: 1691513
URL: http://svn.apache.org/r1691513
Log:
[ARIES-736] Refactored tests and fix problem in incompleteunit test
Added:
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractCarJPAITest.java
aries/trunk/jpa/itests/jpa-container-itest/src/test/resources/
aries/trunk/jpa/itests/jpa-container-itest/src/test/resources/persistence.xml
- copied, changed from r1691493,
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/persistence.xml
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/Car2.java
- copied, changed from r1691493,
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/entities/Car.java
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/packageinfo
- copied, changed from r1691493,
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/entities/packageinfo
Removed:
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/persistence.xml
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/entities/Car.java
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/entities/packageinfo
Modified:
aries/trunk/jpa/itests/jpa-container-itest/pom.xml
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/blueprint/aries/itest/BlueprintTest.java
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/EclipseAdditionalTest.java
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/JPAContainerTest.java
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractJPAItest.java
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/resources/META-INF/persistence.xml
Modified: aries/trunk/jpa/itests/jpa-container-itest/pom.xml
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-itest/pom.xml?rev=1691513&r1=1691512&r2=1691513&view=diff
==============================================================================
--- aries/trunk/jpa/itests/jpa-container-itest/pom.xml (original)
+++ aries/trunk/jpa/itests/jpa-container-itest/pom.xml Fri Jul 17 11:00:50 2015
@@ -411,18 +411,6 @@
<scope>test</scope>
</dependency>
<dependency>
- <groupId>ch.qos.logback</groupId>
- <artifactId>logback-core</artifactId>
- <version>0.9.29</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>ch.qos.logback</groupId>
- <artifactId>logback-classic</artifactId>
- <version>0.9.29</version>
- <scope>test</scope>
- </dependency>
- <dependency>
<groupId>org.ops4j.pax.tinybundles</groupId>
<artifactId>tinybundles</artifactId>
<version>2.0.0</version>
Modified:
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/blueprint/aries/itest/BlueprintTest.java
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/blueprint/aries/itest/BlueprintTest.java?rev=1691513&r1=1691512&r2=1691513&view=diff
==============================================================================
---
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/blueprint/aries/itest/BlueprintTest.java
(original)
+++
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/blueprint/aries/itest/BlueprintTest.java
Fri Jul 17 11:00:50 2015
@@ -21,14 +21,14 @@ import javax.inject.Inject;
import org.apache.aries.jpa.container.itest.entities.Car;
import org.apache.aries.jpa.container.itest.entities.CarService;
-import org.apache.aries.jpa.itest.AbstractJPAItest;
+import org.apache.aries.jpa.itest.AbstractCarJPAITest;
import org.junit.Before;
import org.junit.Test;
import org.ops4j.pax.exam.Configuration;
import org.ops4j.pax.exam.Option;
import org.osgi.service.coordinator.Coordinator;
-public class BlueprintTest extends AbstractJPAItest {
+public class BlueprintTest extends AbstractCarJPAITest {
@Inject
Coordinator coordinator;
Modified:
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/EclipseAdditionalTest.java
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/EclipseAdditionalTest.java?rev=1691513&r1=1691512&r2=1691513&view=diff
==============================================================================
---
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/EclipseAdditionalTest.java
(original)
+++
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/EclipseAdditionalTest.java
Fri Jul 17 11:00:50 2015
@@ -54,7 +54,7 @@ public class EclipseAdditionalTest exten
InputStream testBundle = TinyBundles.bundle()
.set(Constants.BUNDLE_SYMBOLICNAME, "incompleteTestUnit") //
.set("Meta-Persistence", " ") //
- .add("META-INF/persistence.xml",
this.getClass().getResourceAsStream("persistence.xml")) //
+ .add("META-INF/persistence.xml",
this.getClass().getResourceAsStream("/persistence.xml")) //
.build(TinyBundles.withBnd());
return new Option[] {//
baseOptions(),//
Modified:
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/JPAContainerTest.java
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/JPAContainerTest.java?rev=1691513&r1=1691512&r2=1691513&view=diff
==============================================================================
---
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/JPAContainerTest.java
(original)
+++
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/JPAContainerTest.java
Fri Jul 17 11:00:50 2015
@@ -1,3 +1,18 @@
+/* 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.
+ */
package org.apache.aries.jpa.container.itest;
import static org.junit.Assert.assertEquals;
@@ -12,12 +27,12 @@ import javax.persistence.Query;
import javax.persistence.TypedQuery;
import org.apache.aries.jpa.container.itest.entities.Car;
-import org.apache.aries.jpa.itest.AbstractJPAItest;
+import org.apache.aries.jpa.itest.AbstractCarJPAITest;
import org.apache.aries.jpa.supplier.EmSupplier;
import org.junit.Test;
import org.osgi.service.jpa.EntityManagerFactoryBuilder;
-public abstract class JPAContainerTest extends AbstractJPAItest {
+public abstract class JPAContainerTest extends AbstractCarJPAITest {
@Test
public void testCarEMFBuilder() throws Exception {
@@ -80,44 +95,41 @@ public abstract class JPAContainerTest e
ut.begin();
em.joinTransaction();
- Car car = em.find(Car.class, BLUE_CAR_PLATE);
- car.setNumberOfSeats(2);
- car.setEngineSize(2000);
- car.setColour("red");
+ changeToRed(em.find(Car.class, BLUE_CAR_PLATE));
em.remove(em.find(Car.class, GREEN_CAR_PLATE));
em.persist(createBlackCar());
ut.commit();
assertEquals(2l, countQuery.getSingleResult());
-
list = carQuery.getResultList();
assertEquals(2, list.size());
- assertEquals(2, list.get(0).getNumberOfSeats());
- assertEquals(800, list.get(0).getEngineSize());
- assertEquals("black", list.get(0).getColour());
- assertEquals("C3CCC", list.get(0).getNumberPlate());
-
- assertEquals(2, list.get(1).getNumberOfSeats());
- assertEquals(2000, list.get(1).getEngineSize());
- assertEquals("red", list.get(1).getColour());
- assertEquals("A1AAA", list.get(1).getNumberPlate());
-
+ assertBlackCar(list.get(0));
+ assertChangedBlueCar(list.get(1));
+
+ cleanup(em);
+ emSupplier.postCall();
+ }
+
+ private void changeToRed(Car car) {
+ car.setNumberOfSeats(2);
+ car.setEngineSize(2000);
+ car.setColour("red");
+ }
+
+ private void cleanup(EntityManager em) throws Exception {
ut.begin();
em.joinTransaction();
- delete(em, "C3CCC");
- delete(em, "A1AAA");
+ delete(em, BLACK_CAR_PLATE);
+ delete(em, BLUE_CAR_PLATE);
ut.commit();
- emSupplier.postCall();
}
- private Car createBlackCar() {
- Car car;
- car = new Car();
- car.setNumberOfSeats(2);
- car.setEngineSize(800);
- car.setColour("black");
- car.setNumberPlate("C3CCC");
- return car;
+ private void assertChangedBlueCar(Car car) {
+ assertEquals(2, car.getNumberOfSeats());
+ assertEquals(2000, car.getEngineSize());
+ assertEquals("red", car.getColour());
+ assertEquals(BLUE_CAR_PLATE, car.getNumberPlate());
}
+
}
Added:
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractCarJPAITest.java
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractCarJPAITest.java?rev=1691513&view=auto
==============================================================================
---
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractCarJPAITest.java
(added)
+++
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractCarJPAITest.java
Fri Jul 17 11:00:50 2015
@@ -0,0 +1,129 @@
+/* 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.
+ */
+package org.apache.aries.jpa.itest;
+
+import static org.junit.Assert.assertEquals;
+
+import javax.persistence.EntityManager;
+import javax.transaction.UserTransaction;
+
+import org.apache.aries.jpa.container.itest.entities.Car;
+import org.osgi.framework.BundleException;
+
+public abstract class AbstractCarJPAITest extends AbstractJPAItest {
+ protected static final String BLUE_CAR_PLATE = "A1AAA";
+ protected static final String GREEN_CAR_PLATE = "B2BBB";
+ protected static final String BLACK_CAR_PLATE = "C3CCC";
+
+ protected Car createBlueCar() {
+ Car car = new Car();
+ car.setNumberOfSeats(5);
+ car.setEngineSize(1200);
+ car.setColour("blue");
+ car.setNumberPlate(BLUE_CAR_PLATE);
+ return car;
+ }
+
+ protected Car createGreenCar() {
+ Car car;
+ car = new Car();
+ car.setNumberOfSeats(7);
+ car.setEngineSize(1800);
+ car.setColour("green");
+ car.setNumberPlate(GREEN_CAR_PLATE);
+ return car;
+ }
+
+
+ protected Car createBlackCar() {
+ Car car;
+ car = new Car();
+ car.setNumberOfSeats(2);
+ car.setEngineSize(800);
+ car.setColour("black");
+ car.setNumberPlate(BLACK_CAR_PLATE);
+ return car;
+ }
+
+ protected void assertBlueCar(Car car) {
+ assertEquals(5, car.getNumberOfSeats());
+ assertEquals(1200, car.getEngineSize());
+ assertEquals("blue", car.getColour());
+ assertEquals(BLUE_CAR_PLATE, car.getNumberPlate());
+ }
+
+ protected void assertGreenCar(Car car) {
+ assertEquals(7, car.getNumberOfSeats());
+ assertEquals(1800, car.getEngineSize());
+ assertEquals("green", car.getColour());
+ assertEquals(GREEN_CAR_PLATE, car.getNumberPlate());
+ }
+
+ protected void assertBlackCar(Car car) {
+ assertEquals(2, car.getNumberOfSeats());
+ assertEquals(800, car.getEngineSize());
+ assertEquals("black", car.getColour());
+ assertEquals(BLACK_CAR_PLATE, car.getNumberPlate());
+ }
+
+ /**
+ * Create, find and delete car using resource local transactions
+ * @param emf
+ * @throws BundleException
+ */
+ protected void carLifecycleRL(EntityManager em) throws BundleException {
+ em.getTransaction().begin();
+ Car car = createBlueCar();
+ em.persist(car);
+ em.getTransaction().commit();
+
+ Car car2 = em.find(Car.class, BLUE_CAR_PLATE);
+ assertBlueCar(car2);
+ em.getTransaction().begin();
+ em.remove(car2);
+ em.getTransaction().commit();
+ em.close();
+ }
+
+ /**
+ * Create, find and delete car using XA Transactions
+ * @param ut
+ * @param em
+ * @throws Exception
+ */
+ protected void carLifecycleXA(UserTransaction ut, EntityManager em) throws
Exception {
+ ut.begin();
+ em.joinTransaction();
+ delete(em, BLUE_CAR_PLATE);
+ em.persist(createBlueCar());
+ ut.commit();
+
+ Car c = em.find(Car.class, BLUE_CAR_PLATE);
+ assertBlueCar(c);
+
+ ut.begin();
+ em.joinTransaction();
+ delete(em, BLUE_CAR_PLATE);
+ ut.commit();
+ }
+
+ protected void delete(EntityManager em, String plateId) {
+ Car car = em.find(Car.class, plateId);
+ if (car != null) {
+ em.remove(car);
+ }
+ }
+}
Modified:
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractJPAItest.java
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractJPAItest.java?rev=1691513&r1=1691512&r2=1691513&view=diff
==============================================================================
---
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractJPAItest.java
(original)
+++
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/itest/AbstractJPAItest.java
Fri Jul 17 11:00:50 2015
@@ -1,6 +1,20 @@
+/* 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.
+ */
package org.apache.aries.jpa.itest;
-import static org.junit.Assert.assertEquals;
import static org.ops4j.pax.exam.CoreOptions.composite;
import static org.ops4j.pax.exam.CoreOptions.frameworkProperty;
import static org.ops4j.pax.exam.CoreOptions.junitBundles;
@@ -14,11 +28,9 @@ import java.util.Dictionary;
import java.util.Hashtable;
import javax.inject.Inject;
-import javax.persistence.EntityManager;
import javax.persistence.EntityManagerFactory;
import javax.transaction.UserTransaction;
-import org.apache.aries.jpa.container.itest.entities.Car;
import org.junit.Before;
import org.junit.runner.RunWith;
import org.ops4j.pax.exam.Option;
@@ -299,85 +311,4 @@ public abstract class AbstractJPAItest {
}
}
- protected Car createBlueCar() {
- Car car = new Car();
- car.setNumberOfSeats(5);
- car.setEngineSize(1200);
- car.setColour("blue");
- car.setNumberPlate(BLUE_CAR_PLATE);
- return car;
- }
-
- protected Car createGreenCar() {
- Car car;
- car = new Car();
- car.setNumberOfSeats(7);
- car.setEngineSize(1800);
- car.setColour("green");
- car.setNumberPlate(GREEN_CAR_PLATE);
- return car;
- }
-
- protected void assertBlueCar(Car car) {
- assertEquals(5, car.getNumberOfSeats());
- assertEquals(1200, car.getEngineSize());
- assertEquals("blue", car.getColour());
- assertEquals(BLUE_CAR_PLATE, car.getNumberPlate());
- }
-
- protected void assertGreenCar(Car car) {
- assertEquals(7, car.getNumberOfSeats());
- assertEquals(1800, car.getEngineSize());
- assertEquals("green", car.getColour());
- assertEquals(GREEN_CAR_PLATE, car.getNumberPlate());
- }
-
- /**
- * Create, find and delete car using resource local transactions
- * @param emf
- * @throws BundleException
- */
- protected void carLifecycleRL(EntityManager em) throws BundleException {
- em.getTransaction().begin();
- Car car = createBlueCar();
- em.persist(car);
- em.getTransaction().commit();
-
- Car car2 = em.find(Car.class, BLUE_CAR_PLATE);
- assertBlueCar(car2);
- em.getTransaction().begin();
- em.remove(car2);
- em.getTransaction().commit();
- em.close();
- }
-
- /**
- * Create, find and delete car using XA Transactions
- * @param ut
- * @param em
- * @throws Exception
- */
- protected void carLifecycleXA(UserTransaction ut, EntityManager em) throws
Exception {
- ut.begin();
- em.joinTransaction();
- delete(em, BLUE_CAR_PLATE);
- em.persist(createBlueCar());
- ut.commit();
-
- Car c = em.find(Car.class, BLUE_CAR_PLATE);
- assertBlueCar(c);
-
- ut.begin();
- em.joinTransaction();
- delete(em, BLUE_CAR_PLATE);
- ut.commit();
- }
-
- protected void delete(EntityManager em, String plateId) {
- Car car = em.find(Car.class, plateId);
- if (car != null) {
- em.remove(car);
- }
- }
-
}
Copied:
aries/trunk/jpa/itests/jpa-container-itest/src/test/resources/persistence.xml
(from r1691493,
aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/persistence.xml)
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-itest/src/test/resources/persistence.xml?p2=aries/trunk/jpa/itests/jpa-container-itest/src/test/resources/persistence.xml&p1=aries/trunk/jpa/itests/jpa-container-itest/src/test/java/org/apache/aries/jpa/container/itest/persistence.xml&r1=1691493&r2=1691513&rev=1691513&view=diff
==============================================================================
(empty)
Copied:
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/Car2.java
(from r1691493,
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/entities/Car.java)
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/Car2.java?p2=aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/Car2.java&p1=aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/entities/Car.java&r1=1691493&r2=1691513&rev=1691513&view=diff
==============================================================================
---
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/entities/Car.java
(original)
+++
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/Car2.java
Fri Jul 17 11:00:50 2015
@@ -16,13 +16,13 @@
* specific language governing permissions and limitations
* under the License.
*/
-package org.apache.aries.jpa.container.itest.entities;
+package org.apache.aries.jpa.container.itest.eclipselink.entities;
import javax.persistence.Entity;
import javax.persistence.Id;
@Entity
-public class Car {
+public class Car2 {
@Id
private String numberPlate;
Copied:
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/packageinfo
(from r1691493,
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/entities/packageinfo)
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/packageinfo?p2=aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/eclipselink/entities/packageinfo&p1=aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/java/org/apache/aries/jpa/container/itest/entities/packageinfo&r1=1691493&r2=1691513&rev=1691513&view=diff
==============================================================================
(empty)
Modified:
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/resources/META-INF/persistence.xml
URL:
http://svn.apache.org/viewvc/aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/resources/META-INF/persistence.xml?rev=1691513&r1=1691512&r2=1691513&view=diff
==============================================================================
---
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/resources/META-INF/persistence.xml
(original)
+++
aries/trunk/jpa/itests/jpa-container-testbundle-eclipselink/src/main/resources/META-INF/persistence.xml
Fri Jul 17 11:00:50 2015
@@ -11,23 +11,9 @@
language governing permissions and limitations under the License. -->
<persistence version="2.1"
xmlns="http://xmlns.jcp.org/xml/ns/persistence"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/persistence
-
http://xmlns.jcp.org/xml/ns/persistence/persistence_2_1.xsd">
-
- <persistence-unit name="test-unit"
- transaction-type="JTA">
- <description>Test persistence unit for the JPA Container and Context
iTests</description>
-
<jta-data-source>osgi:service/javax.sql.DataSource/(transactional=true)</jta-data-source>
- <class>org.apache.aries.jpa.container.itest.entities.Car</class>
- <exclude-unlisted-classes>true</exclude-unlisted-classes>
- <properties>
- <property name="eclipselink.target-database" value="Derby" />
- <property name="eclipselink.ddl-generation"
value="drop-and-create-tables" />
- <property name="eclipselink.ddl-generation.output-mode"
- value="database" />
- </properties>
- </persistence-unit>
-
+ xsi:schemaLocation="
+ http://xmlns.jcp.org/xml/ns/persistence
http://xmlns.jcp.org/xml/ns/persistence/persistence_2_1.xsd
+ ">
<persistence-unit name="script-test-unit"
transaction-type="RESOURCE_LOCAL">
<properties>