void () { configureByFiles(null, BASE_PATH + getTestName(false) + ".xml", BASE_PATH + getTestName(false) + ".xsd"); final String url = "http://www.foo.org/schema"; ExternalResourceManagerExImpl.registerResourceTemporarily(url, getTestName(false) + ".xsd", getTestRootDisposable()); final String url2 = "http://www.bar.org/foo"; ExternalResourceManagerExImpl.registerResourceTemporarily(url2, getTestName(false) + ".xsd", getTestRootDisposable()); final Collection<HighlightInfo> infoCollection = doDoTest(true, false, true); final TextRange startTagNameRange = XmlTagUtil.getStartTagNameElement(((XmlFile)myFile).getDocument().getRootTag()).getTextRange(); HighlightInfo infoAtTagName = null; for(HighlightInfo info:infoCollection) { if (info.startOffset == startTagNameRange.getStartOffset() && info.endOffset == startTagNameRange.getEndOffset()) { if (info.getDescription() .equals("Attribute \"foo\" bound to namespace \"http://www.w3.org/2000/xmlns/\" was already specified for element \"root\".")) { infoAtTagName = info; break; } } } assertNotNull( infoAtTagName ); }