gdamour 2004/11/11 08:27:44
Modified: modules/openejb-builder/src/test/org/openejb/deployment
CMPSystemMethodIndicesTest.java
Log:
GERONIMO-467: ejbRemove does not work for CMP with MTM relationship
GERONIMO-468: CMP - cascade delete is not supported
o update CMPRemoveMethod such that relationships are reset and EJB in
cascade-delete relationships are also removed; and
o update the way the various TranQL schema are built in order to retrieve
the EJB defining a cascade-delete relationship.
Revision Changes Path
1.2 +5 -2
openejb/modules/openejb-builder/src/test/org/openejb/deployment/CMPSystemMethodIndicesTest.java
Index: CMPSystemMethodIndicesTest.java
===================================================================
RCS file:
/home/projects/openejb/scm/openejb/modules/openejb-builder/src/test/org/openejb/deployment/CMPSystemMethodIndicesTest.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- CMPSystemMethodIndicesTest.java 10 Nov 2004 01:35:10 -0000 1.1
+++ CMPSystemMethodIndicesTest.java 11 Nov 2004 13:27:44 -0000 1.2
@@ -47,6 +47,7 @@
*/
package org.openejb.deployment;
+import java.util.Collections;
import java.util.LinkedHashMap;
import java.util.Map;
import javax.ejb.EntityContext;
@@ -55,6 +56,8 @@
import org.openejb.deployment.entity.MockCMPEJB;
import org.openejb.dispatch.InterfaceMethodSignature;
import org.openejb.dispatch.SystemMethodIndices;
+import org.tranql.cache.CacheSlot;
+import org.tranql.cache.CacheTable;
/**
*
@@ -67,7 +70,7 @@
public void testSystemMethodIndices() throws Exception {
CMPContainerBuilder builder = new CMPContainerBuilder();
builder.setClassLoader(MockCMPEJB.class.getClassLoader());
- Map vopMap = builder.buildVopMap(MockCMPEJB.class, null, null, null,
null, null, null, null, new LinkedHashMap());
+ Map vopMap = builder.buildVopMap(MockCMPEJB.class, new
CacheTable("mock", new CacheSlot[0], null, null, null, null),
Collections.EMPTY_MAP, null, null, null, null, null, null, new LinkedHashMap());
InterfaceMethodSignature[] signatures = (InterfaceMethodSignature[])
vopMap.keySet().toArray(new InterfaceMethodSignature[vopMap.size()]);
SystemMethodIndices systemMethodIndices =
SystemMethodIndices.createSystemMethodIndices(signatures, "setEntityContext",
new String(EntityContext.class.getName()), "unsetEntityContext");
assertFalse(systemMethodIndices.getEjbActivateInvocation(null).getMethodIndex()
== -1);