1 22 package org.jboss.ejb3.test.regression.salesforce7123.unit; 23 24 import java.util.List ; 25 import org.jboss.ejb3.test.regression.salesforce7123.BaseData; 26 import org.jboss.ejb3.test.regression.salesforce7123.DataAccessRemote; 27 import org.jboss.ejb3.test.regression.salesforce7123.MyBusinessSessionRemote; 28 import org.jboss.test.JBossTestCase; 29 import junit.framework.Test; 30 31 38 39 public class NotSupportedUnitTestCase 40 extends JBossTestCase 41 { 42 org.jboss.logging.Logger log = getLog(); 43 44 static boolean deployed = false; 45 static int test = 0; 46 47 public NotSupportedUnitTestCase(String name) 48 { 49 50 super(name); 51 52 } 53 54 public void testInheritance() throws Exception 55 { 56 DataAccessRemote remote = (DataAccessRemote) getInitialContext().lookup("DataAccessBean/remote"); 57 remote.initialize(); 58 MyBusinessSessionRemote biz =(MyBusinessSessionRemote) getInitialContext().lookup("MyBusinessSessionBean/remote"); 59 biz.getMyBeans(); 60 List real = remote.findMyBeans(); 61 assertEquals(real.size(), 1); 62 BaseData data = (BaseData)real.get(0); 63 assertEquals("Bill", data.getName()); 64 assertEquals(1, data.getChildren().size()); 65 } 66 67 public static Test suite() throws Exception 68 { 69 return getDeploySetup(NotSupportedUnitTestCase.class, "salesforce-7123.jar"); 70 } 71 72 } 73 | Popular Tags |