Package org.jboss.test.cmp2.ejbselect

Examples of org.jboss.test.cmp2.ejbselect.ALocalHome.create()


   public void testHsqldbIntegerKeyGenerator() throws Exception
   {
      Context ctx = new InitialContext();
      IntegerPKLocalHome home = (IntegerPKLocalHome) ctx.lookup("java:comp/env/local/TestHsqldbIntegerEJB");
      UnknownPKLocal ejb1 = home.create("testHsqldbIntegerKeyGenerator");
      UnknownPKLocal ejb2 = home.create("testHsqldbIntegerKeyGenerator");
      try
      {
         Integer key = (Integer) ejb1.getPrimaryKey();
         UnknownPKLocal ejb1a = home.findByPrimaryKey(key);
         assertTrue(ejb1.isIdentical(ejb1a));
View Full Code Here


   {
      Context ctx = new InitialContext();
      IntegerPKLocalHome home = (IntegerPKLocalHome) ctx.lookup("java:comp/env/local/InvalidHsqldbIntegerEJB");
      try
      {
         UnknownPKLocal ejb1 = home.create("testInvalidHsqldbIntegerKeyGenerator");
         Object key = ejb1.getPrimaryKey();
         assertTrue("InvalidHsqldbIntegerEJB key != null", key != null);
      }
      catch(Exception e)
      {
View Full Code Here

   }

   public void testJBAS1249() throws Exception
   {
      UnknownPKHome home = getUnknownPKRemoteHome("remote/TestPkSqlEJB");
      UnknownPK ejb = home.create("kloop");
      try
      {
         ejb.getHandle().getEJBObject();
      }
      catch(Exception e)
View Full Code Here

   }

   public void testOtherKeyGenerator() throws Exception
   {
      UnknownPKLocalHome home = getUnknownPKHome("local/TestOtherEJB");
      UnknownPKLocal ejb1 = home.create("testOtherKeyGenerator1");
      UnknownPKLocal ejb2 = home.create("testOtherKeyGenerator2");
      try
      {
         UnknownPKLocal ejb1a = home.findByPrimaryKey(ejb1.getPrimaryKey());
         assertTrue(ejb1.isIdentical(ejb1a));
View Full Code Here

   public void testOtherKeyGenerator() throws Exception
   {
      UnknownPKLocalHome home = getUnknownPKHome("local/TestOtherEJB");
      UnknownPKLocal ejb1 = home.create("testOtherKeyGenerator1");
      UnknownPKLocal ejb2 = home.create("testOtherKeyGenerator2");
      try
      {
         UnknownPKLocal ejb1a = home.findByPrimaryKey(ejb1.getPrimaryKey());
         assertTrue(ejb1.isIdentical(ejb1a));
         assertEquals("testOtherKeyGenerator1", ejb1a.getValue());
View Full Code Here

   }

   public void testUUIDKeyGenerator() throws Exception
   {
      UnknownPKLocalHome home = getUnknownPKHome("local/TestUUIDKeyGenEJB");
      UnknownPKLocal ejb1 = home.create("testUUIDKeyGenerator");
      UnknownPKLocal ejb2 = home.create("testUUIDKeyGenerator");
      try
      {
         UnknownPKLocal ejb1a = home.findByPrimaryKey(ejb1.getPrimaryKey());
         assertTrue(ejb1.isIdentical(ejb1a));
View Full Code Here

   public void testUUIDKeyGenerator() throws Exception
   {
      UnknownPKLocalHome home = getUnknownPKHome("local/TestUUIDKeyGenEJB");
      UnknownPKLocal ejb1 = home.create("testUUIDKeyGenerator");
      UnknownPKLocal ejb2 = home.create("testUUIDKeyGenerator");
      try
      {
         UnknownPKLocal ejb1a = home.findByPrimaryKey(ejb1.getPrimaryKey());
         assertTrue(ejb1.isIdentical(ejb1a));
         assertTrue(ejb1.isIdentical(ejb2) == false);
View Full Code Here

   }

   public void testPkSQLKeyGenerator() throws Exception
   {
      UnknownPKLocalHome home = getUnknownPKHome("local/TestPkSqlEJB");
      UnknownPKLocal ejb1 = home.create("testPkSQLKeyGenerator");
      Thread.sleep(50);
      UnknownPKLocal ejb2 = home.create("testPkSQLKeyGenerator");
      try
      {
         UnknownPKLocal ejb1a = home.findByPrimaryKey(ejb1.getPrimaryKey());
View Full Code Here

   public void testPkSQLKeyGenerator() throws Exception
   {
      UnknownPKLocalHome home = getUnknownPKHome("local/TestPkSqlEJB");
      UnknownPKLocal ejb1 = home.create("testPkSQLKeyGenerator");
      Thread.sleep(50);
      UnknownPKLocal ejb2 = home.create("testPkSQLKeyGenerator");
      try
      {
         UnknownPKLocal ejb1a = home.findByPrimaryKey(ejb1.getPrimaryKey());
         assertTrue(ejb1.isIdentical(ejb1a));
         assertTrue(ejb1.isIdentical(ejb2) == false);
View Full Code Here

   }

   public void testHsqldbKeyGenerator() throws Exception
   {
      UnknownPKLocalHome home = getUnknownPKHome("local/TestHsqldbEJB");
      UnknownPKLocal ejb1 = home.create("testHsqldbKeyGenerator");
      UnknownPKLocal ejb2 = home.create("testHsqldbKeyGenerator");
      try
      {
         UnknownPKLocal ejb1a = home.findByPrimaryKey(ejb1.getPrimaryKey());
         assertTrue(ejb1.isIdentical(ejb1a));
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.