Package org.jboss.test.spring.support

Examples of org.jboss.test.spring.support.BeanNameAwareBean


      return suite(BeanNameAwareSpringTestCase.class);
   }

   public void testConfigure() throws Exception
   {
      BeanNameAwareBean testBean = (BeanNameAwareBean) getBean("testBean", ControllerState.INSTANTIATED);
      assertNotNull(testBean);
      assertEquals("testBean" , testBean.getBeanName());
      BeanNameAwareBean subTestBean = (BeanNameAwareBean) getBean("subTestBean", ControllerState.INSTANTIATED);
      assertNotNull(subTestBean);
      assertEquals("subTestBean" , subTestBean.getBeanName());
      IntBeanNameAwareBean intTestBean = (IntBeanNameAwareBean) getBean("intTestBean", ControllerState.INSTANTIATED);
      assertNotNull(intTestBean);
      assertEquals("intTestBean" , intTestBean.getName());

      BeanNameAwareBean otherBean = (BeanNameAwareBean) getBean("testBeanWithExisingName", ControllerState.INSTANTIATED);
      assertNotNull(otherBean);
      assertEquals("OtherBean" , otherBean.getBeanName());
      BeanNameAwareBean subOtherBean = (BeanNameAwareBean) getBean("subTestBeanWithExisingName", ControllerState.INSTANTIATED);
      assertNotNull(subOtherBean);
      assertEquals("subOtherBean" , subOtherBean.getBeanName());
      IntBeanNameAwareBean intOtherBean = (IntBeanNameAwareBean) getBean("intTestBeanWithExisingName", ControllerState.INSTANTIATED);
      assertNotNull(intOtherBean);
      assertEquals("intOtherBean" , intOtherBean.getName());
   }
View Full Code Here

TOP

Related Classes of org.jboss.test.spring.support.BeanNameAwareBean

Copyright © 2018 www.massapicom. 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.