void () { final XmlTag tagFromText = XmlElementFactory.getInstance(getProject()).createTagFromText("<a/>"); WriteCommandAction.runWriteCommandAction(null, () -> tagFromText.getValue().setText("<")); assertEquals("<", tagFromText.getValue().getTextElements()[0].getValue()); }