use of com.intellij.psi.css.inspections.CssInvalidElementInspection in project intellij-plugins by JetBrains.
the class FlexHighlightingTest method testUnresolvedClassReference2.
@JSTestOptions({ JSTestOption.WithGumboSdk })
public void testUnresolvedClassReference2() throws Throwable {
enableInspectionTool(new CssInvalidElementInspection());
JSTestUtils.disableFileHeadersInTemplates(getProject());
final String testName = getTestName(false);
doHighlightingWithInvokeFixAndCheckResult("Create MXML Component 'Missing'", "mxml");
final VirtualFile expectedFile = LocalFileSystem.getInstance().findFileByPath(getTestDataPath() + getBasePath() + "/" + testName + "_2.mxml");
final VirtualFile createdFile = VfsUtilCore.findRelativeFile("/foo/boo2/Missing.mxml", ModuleRootManager.getInstance(myModule).getSourceRoots()[0]);
assertNotNull(expectedFile);
assertNotNull(createdFile);
FileDocumentManager.getInstance().saveAllDocuments();
String expected = StringUtil.convertLineSeparators(VfsUtilCore.loadText(expectedFile));
Properties properties = FileTemplateManager.getInstance(getProject()).getDefaultProperties();
expected = FileTemplateUtil.mergeTemplate(properties, expected, false);
assertEquals(expected, StringUtil.convertLineSeparators(VfsUtilCore.loadText(createdFile)));
}
use of com.intellij.psi.css.inspections.CssInvalidElementInspection in project intellij-plugins by JetBrains.
the class FlexHighlightingTest method testFlexSpecificFunctionsInCss.
@JSTestOptions({ JSTestOption.WithCssSupportLoader, JSTestOption.WithFlexFacet })
public void testFlexSpecificFunctionsInCss() throws Exception {
enableInspectionTool(new CssInvalidElementInspection());
enableInspectionTool(new CssInvalidPropertyValueInspection());
enableInspectionTool(new CssInvalidFunctionInspection());
doTestFor(true, getTestName(false) + ".css");
}
use of com.intellij.psi.css.inspections.CssInvalidElementInspection in project intellij-plugins by JetBrains.
the class FlexHighlightingTest method testUnresolvedClassReference.
@JSTestOptions({ JSTestOption.WithGumboSdk })
public void testUnresolvedClassReference() throws Throwable {
enableInspectionTool(new CssInvalidElementInspection());
JSTestUtils.disableFileHeadersInTemplates(getProject());
final String testName = getTestName(false);
doHighlightingWithInvokeFixAndCheckResult(JSBundle.message("javascript.create.class.intention.name", "MyZuperClass"), "mxml");
final VirtualFile expectedFile = LocalFileSystem.getInstance().findFileByPath(getTestDataPath() + getBasePath() + "/" + testName + "_2.as");
final VirtualFile createdFile = VfsUtilCore.findRelativeFile("/foo/MyZuperClass.as", ModuleRootManager.getInstance(myModule).getSourceRoots()[0]);
assertNotNull(expectedFile);
assertNotNull(createdFile);
FileDocumentManager.getInstance().saveAllDocuments();
assertEquals(StringUtil.convertLineSeparators(VfsUtilCore.loadText(expectedFile)), StringUtil.convertLineSeparators(VfsUtilCore.loadText(createdFile)));
}
use of com.intellij.psi.css.inspections.CssInvalidElementInspection in project intellij-plugins by JetBrains.
the class FlexHighlightingTest method testFlexWithMockFlex.
@JSTestOptions({ JSTestOption.WithJsSupportLoader, JSTestOption.WithFlexFacet })
public void testFlexWithMockFlex() throws Exception {
enableInspectionTool(new CssInvalidElementInspection());
final String testName = getTestName(false);
doHighlightingWithInvokeFixAndCheckResult("Add override modifier", "mxml", testName + ".mxml", testName + "_2.as");
}
Aggregations