// /apps/validation/1/resource/child1 will miss its mandatory "hello" property
Resource resourceChild = rr.create(testResource, "child1", new HashMap<String, Object>(){{
put(JcrConstants.JCR_PRIMARYTYPE, JcrConstants.NT_UNSTRUCTURED);
}});
Resource resourceGrandChild = rr.create(resourceChild, "grandChild1", new HashMap<String, Object>(){{
put(JcrConstants.JCR_PRIMARYTYPE, JcrConstants.NT_UNSTRUCTURED);
}});
rr.commit();
}
ValidationModel vm = validationService.getValidationModel("sling/validation/test", "/apps/validation/1/resource");