@Test
@Ignore
public void testValidateComplexUnstructuredNodeTypes() throws IOException, RepositoryException, ParseException, ConfigurationException {

    NodeContext nodeContext = new NodeContextImpl("/apps/test/node4", Paths.get("node4"), Paths.get(""));
    Map<String, DocViewProperty> props = new HashMap<>();
    DocViewProperty property = new DocViewProperty("{}prop1", new String[] { "value1" }, false, PropertyType.STRING);
    props.put("{}prop1", property);
    props.put(NameConstants.JCR_PRIMARYTYPE.toString(), new DocViewProperty(NameConstants.JCR_PRIMARYTYPE.toString(),
            new String[] { "nt:unstructured" }, false, PropertyType.STRING));
    // no primary type
    DocViewNode node = new DocViewNode("jcr:root", "jcr:root", null, props, null, "sling:Folder");
    Assert.assertNull(validator.validate(node, nodeContext, false));
    props.put(NameConstants.JCR_PRIMARYTYPE.toString(),
            new DocViewProperty(NameConstants.JCR_PRIMARYTYPE.toString(), new String[] { "value1" }, false, PropertyType.STRING));
    node = new DocViewNode("test", "test", null, props, null, "nt:folder");
    ValidationExecutorTest.assertViolation(validator.validate(node, nodeContext, false),
            new ValidationMessage(ValidationMessageSeverity.ERROR,
                    String.format(NodeTypeValidator.MESSAGE_PROPERTY_NOT_ALLOWED, property, "nt:folder",
                            "No property definition found for name!")));
}