1 22 package org.jboss.test.aop.test; 23 24 import javax.management.MBeanServerConnection ; 25 import javax.management.ObjectName ; 26 27 import junit.framework.Test; 28 import junit.framework.TestSuite; 29 30 import org.jboss.test.JBossTestCase; 31 32 38 39 public class TxUnitTestCase 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 TxUnitTestCase(String name) 48 { 49 super(name); 50 } 51 52 public void testXml() throws Exception 53 { 54 MBeanServerConnection server = getServer(); 55 ObjectName testerName = new ObjectName ("jboss.aop:name=TxTester"); 56 Object [] params = {}; 57 String [] sig = {}; 58 server.invoke(testerName, "testXml", params, sig); 59 } 60 61 public void testAnnotated() throws Exception 62 { 63 MBeanServerConnection server = getServer(); 64 ObjectName testerName = new ObjectName ("jboss.aop:name=TxTester"); 65 Object [] params = {}; 66 String [] sig = {}; 67 server.invoke(testerName, "testAnnotated", params, sig); 68 } 69 70 public static Test suite() throws Exception 71 { 72 TestSuite suite = new TestSuite(); 73 suite.addTest(new TestSuite(TxUnitTestCase.class)); 74 75 AOPTestSetup setup = new AOPTestSetup(suite, "aoptest.sar"); 76 return setup; 77 } 78 79 } 80 | Popular Tags |