use of org.mule.metadata.java.api.JavaTypeLoader in project mule by mulesoft.
the class GroupValueSetterTestCase method before.
@Before
public void before() throws Exception {
final String personalInfo = "personalInfo";
ParameterGroupDescriptor group = new ParameterGroupDescriptor("group", new TypeWrapper(PersonalInfo.class, new JavaTypeLoader(Thread.currentThread().getContextClassLoader())), ExtensionsTypeLoaderFactory.getDefault().createTypeLoader().load(PersonalInfo.class), getField(HeisenbergExtension.class, personalInfo, reflectionCache).get(), null);
Map<String, Object> resultMap = new HashMap<>();
resultMap.put("name", NAME);
resultMap.put("age", AGE);
resultMap.put("dateOfBirth", DATE);
when(result.asMap()).thenReturn(resultMap);
valueSetter = new GroupValueSetter(group, () -> reflectionCache);
}
Aggregations