Package org.jboss.test.kernel.inject.support

Examples of org.jboss.test.kernel.inject.support.PropertyInjectTestObject


      assertNull(context.getTarget());
      assertEquals(context.getState(), ControllerState.NOT_INSTALLED);

      ControllerState state = change(context, ControllerState.INSTALLED);
      assertEquals(ControllerState.INSTALLED, state);
      PropertyInjectTestObject injectee = (PropertyInjectTestObject)context.getTarget();
      assertNotNull(injectee);
      assertNull(injectee.getTesterInterface());

      KernelControllerContext tester = getControllerContext("tester", ControllerState.NOT_INSTALLED);
      assertNotNull(tester);
      change(tester, ControllerState.INSTALLED);

      assertNotNull(injectee.getTesterInterface());
   }
View Full Code Here


      return "MultipleContextualInjection.xml";
   }

   protected void checkInjection()
   {
      PropertyInjectTestObject test = (PropertyInjectTestObject) getBean("testObject", ControllerState.DESCRIBED);
      assertNull(test);
   }
View Full Code Here

      return "PropertyContextualInjection.xml";
   }

   protected void checkInjection()
   {
      PropertyInjectTestObject test1 = (PropertyInjectTestObject) getBean("testObject1");
      assertNotNull(test1.getTesterInterface());

      PropertyInjectTestObject test2 = (PropertyInjectTestObject) getBean("testObject2");
      assertNotNull(test2.getDuplicateTester());

      PropertyInjectTestObject test3 = (PropertyInjectTestObject) getBean("testObject3");
      assertFalse(test3.getCollection().isEmpty());

      PropertyInjectTestObject test4 = (PropertyInjectTestObject) getBean("testObject4");
      assertFalse(test4.getMap().isEmpty());     
   }
View Full Code Here

      return "CandidateContextualInjection.xml";
   }

   protected void checkInjection()
   {
      PropertyInjectTestObject test1 = (PropertyInjectTestObject) getBean("testObject1");
      PropertyInjectTestObject test2 = (PropertyInjectTestObject) getBean("testObject2");

      TesterInterface ignored = (TesterInterface)getBean("ignored");
      assertNotNull(ignored);
      TesterInterface used = (TesterInterface)getBean("used");
      assertNotNull(used);
      assertEquals(used, test1.getTesterInterface());

      assertNull(test2.getDuplicateTester());
   }
View Full Code Here

TOP

Related Classes of org.jboss.test.kernel.inject.support.PropertyInjectTestObject

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.