// there should be six children
assertEditorHasChildren(6, editor_page);
ShapeNodeEditPart target = assertHasInputTextField(editor_page, "target", false);
assertGenerated(target);
GeneratedElementHandler handler = new GeneratedElementHandler(target);
assertTrue("we should have incoming edges", handler.needsConfirmation());
assertEquals("There should only be one element to confirm", 1, handler.getConfirmationElements().size());
GeneratedElement toConfirm = (GeneratedElement) handler.getConfirmationElements().get(0);
assertEqualsOneOf(new String[] {
"The generated element 'InputTextField 'target'' contains elements which are connected to non-generated elements:\n\n" +
"EventTrigger onChange\n" +
"CompositeOperation 'update'\n\n" +
"Deleting 'InputTextField 'target'' will also delete these generated elements, currently in use:\n\n" +
"CompositeOperation 'update'\n" +
"EventTrigger onChange",
// swap Event/Operation around
"The generated element 'InputTextField 'target'' contains elements which are connected to non-generated elements:\n\n" +
"CompositeOperation 'update'\n" +
"EventTrigger onChange\n\n" +
"Deleting 'InputTextField 'target'' will also delete these generated elements, currently in use:\n\n" +
"CompositeOperation 'update'\n" +
"EventTrigger onChange"
}, handler.getConfirmationMessage(toConfirm));
}