use of com.intellij.javascript.flex.mxml.schema.FlexMxmlNSDescriptor in project intellij-plugins by JetBrains.
the class FlexHighlightingTest method testDumbMode.
@JSTestOptions({ JSTestOption.WithFlexFacet, JSTestOption.WithGumboSdk })
@SuppressWarnings({ "ConstantConditions" })
public void testDumbMode() throws Exception {
DumbServiceImpl.getInstance(getProject()).setDumb(true);
((DaemonCodeAnalyzerImpl) DaemonCodeAnalyzer.getInstance(getProject())).mustWaitForSmartMode(false, getTestRootDisposable());
XmlNSDescriptor nsDescriptor;
try {
assertTrue(DumbService.isDumb(getProject()));
configureByFile(getBasePath() + "/dumbMode.mxml");
nsDescriptor = ((XmlFile) getFile()).getDocument().getRootTagNSDescriptor();
assertTrue(nsDescriptor.toString(), nsDescriptor instanceof FlexMxmlNSDescriptor);
doDoTest(true, true);
} finally {
DumbServiceImpl.getInstance(getProject()).setDumb(false);
}
nsDescriptor = ((XmlFile) getFile()).getDocument().getRootTagNSDescriptor();
assertTrue(nsDescriptor.toString(), nsDescriptor instanceof FlexMxmlNSDescriptor);
doDoTest(true, true);
}
use of com.intellij.javascript.flex.mxml.schema.FlexMxmlNSDescriptor in project intellij-plugins by JetBrains.
the class FlexHighlightingTest method testAfterRename.
@JSTestOptions({ JSTestOption.WithFlexFacet, JSTestOption.WithGumboSdk })
@SuppressWarnings({ "ConstantConditions" })
public void testAfterRename() throws Exception {
configureByFile(getBasePath() + "/afterRename.xml");
XmlNSDescriptor nsDescriptor = ((XmlFile) getFile()).getDocument().getRootTagNSDescriptor();
assertTrue(nsDescriptor.toString(), nsDescriptor instanceof XmlNSDescriptorImpl);
doDoTest(true, true);
new RenameProcessor(getProject(), getFile(), "afterRename.mxml", false, false).run();
assertEquals("afterRename.mxml", getFile().getName());
assertFalse(myFile.isValid());
myFile = myPsiManager.findFile(getFile().getVirtualFile().getParent().findChild("afterRename.mxml"));
assertTrue(myFile.isValid());
nsDescriptor = ((XmlFile) getFile()).getDocument().getRootTagNSDescriptor();
assertTrue(nsDescriptor.toString(), nsDescriptor instanceof FlexMxmlNSDescriptor);
doDoTest(true, true);
}
Aggregations