/** test for method getPropertyValue(..) Multiple */ public void testGetPropertyValueMultiple() throws Exception { vo.setFullName("John Smith"); vo.setActive(true); holder.setValueObject(vo); assertEquals("FullName", "John Smith", holder.getPropertyValue("fullName")); assertEquals("active", Boolean.TRUE, holder.getPropertyValue("active")); }
/** test for method getPropertyValue(..) Multiple access of same */ public void testGetPropertyValueMultipleAccessOfSame() throws Exception { vo.setFullName("John Smith"); holder.setValueObject(vo); assertEquals("FullName", "John Smith", holder.getPropertyValue("fullName")); assertEquals("FullName", "John Smith", holder.getPropertyValue("fullName")); assertEquals("FullName", "John Smith", holder.getPropertyValue("fullName")); // Now make sure only 1 entry in Map assertEquals("Size of map", 1, holder.getPropertyAccessors().size()); }