1 package org.apache.geronimo.itest.naming.client; 2 3 import java.sql.Connection ; 4 import java.lang.reflect.Method ; 5 import java.lang.reflect.InvocationTargetException ; 6 import javax.naming.InitialContext ; 7 import javax.naming.Name ; 8 import javax.naming.NamingException ; 9 import javax.sql.DataSource ; 10 import javax.jms.ConnectionFactory ; 11 import javax.jms.Queue ; 12 import javax.jms.Topic ; 13 14 import org.apache.geronimo.naming.java.javaURLContextFactory; 15 import org.apache.geronimo.naming.java.RootContext; 16 import org.apache.geronimo.kernel.Kernel; 17 import org.apache.notgeronimo.itests.naming.common.Test; 18 19 20 public class App { 21 public static void main(String [] args) throws Exception { 22 23 String methodName = args[0]; 24 Method m = App.class.getMethod(methodName, new Class [] {}); 25 26 App app = new App(); 27 try { 28 m.invoke(app, new Object [] {}); 29 System.out.println(methodName + " OK"); 30 } catch (Throwable e) { 31 e.printStackTrace(System.out); 32 } 33 } 34 35 public void testWebService() throws Exception { 36 Test test = new Test(); 37 test.testWebServiceLookup(); 38 39 } 40 41 public void testResourceRefLookup() throws Exception { 42 Test test = new Test(); 43 test.testResourceRefLookup(); 44 } 45 46 } 47 | Popular Tags |