void () { Annotator annotator = new MyAnnotator(); Language javaLanguage = JavaFileType.INSTANCE.getLanguage(); LanguageAnnotators.INSTANCE.addExplicitExtension(javaLanguage, annotator); enableInspectionTool(new HighlightVisitorBasedInspection().setRunAnnotators(true)); try { //todo: use LightQuickFixParameterizedTestCase to get separate tests for all data files in testData directory. doAllTests(createWrapper()); } finally { LanguageAnnotators.INSTANCE.removeExplicitExtension(javaLanguage, annotator); } }