1 22 package org.jboss.ejb3.test.naming.unit; 23 24 import junit.framework.Test; 25 import junit.framework.TestSuite; 26 27 import org.jboss.logging.Logger; 28 import org.jboss.test.JBossTestCase; 29 30 import org.jboss.ejb3.test.naming.Stateful; 31 32 36 public class BindFailureTestCase extends JBossTestCase 37 { 38 private static final Logger log = Logger.getLogger(BindFailureTestCase.class); 39 40 45 public BindFailureTestCase(String name) 46 { 47 super(name); 48 } 49 50 public void testJndiBindingExceptions() throws Exception 51 { 52 try 53 { 54 this.redeploy("bind-failure-test.jar"); 57 this.redeploy("bind-failure-test.jar"); 58 } catch (Exception e) 60 { 61 log.info("caught " + e.getClass().getName() + " " + e.getMessage() + " " + e.getCause()); 62 System.out.println("caught " + e.getClass().getName() + " " + e.getMessage() + " " + e.getCause()); 63 fail(); 64 } 65 66 this.undeploy("bind-failure-test.jar"); 67 68 } 69 70 public static Test suite() throws Exception 71 { 72 TestSuite suite = new TestSuite(); 73 return suite; 74 } 75 76 } 77 | Popular Tags |