public void testGetArgNames() throws Exception {
   BeanDesc beanDesc = BeanDescFactory.getBeanDesc(getDaoClass("AnnotationTestDaoImpl"));
   DaoAnnotationReader reader = readerFactory.createDaoAnnotationReader(beanDesc);
   assertEquals("1", Employee.class, reader.getBeanClass());
   Method method = beanDesc.getMethods("withArgumentAnnotaion")[0];
   String[] names = reader.getArgNames(method);
   assertEquals("2", 2, names.length);
   assertEquals("2", "arg1", names[0]);
   assertEquals("2", "arg2", names[1]);
   // getArgNames return 0 length array if args annotation is not
   // specified.
   Method method2 = beanDesc.getMethods("withNoAnnotaion")[0];
   String[] names2 = reader.getArgNames(method2);
   assertEquals("3", 0, names2.length);
   // annotationReader must read subclass annotation
   Method method3 = beanDesc.getMethods("subclassMethod")[0];
   String[] names3 = reader.getArgNames(method3);
   assertEquals("3", 1, names3.length);
 }
 public void testGetNullBean() {
   BeanDesc beanDesc = BeanDescFactory.getBeanDesc(getDaoClass("DummyDao"));
   DaoAnnotationReader reader = readerFactory.createDaoAnnotationReader(beanDesc);
   assertEquals(NullBean.class, reader.getBeanClass());
 }
 public void testGetBean() {
   BeanDesc beanDesc1 = BeanDescFactory.getBeanDesc(getDaoClass("AnnotationTestDaoImpl"));
   DaoAnnotationReader reader1 = readerFactory.createDaoAnnotationReader(beanDesc1);
   assertEquals(Employee.class, reader1.getBeanClass());
 }