void () { doWithEditorConfigDisabled(()->myFixture.configureByFile("test.txt")); myFixture.copyFileToProject(".editorconfig"); VirtualFile sourceFile = getFile().getVirtualFile(); assertEquals(StandardCharsets.UTF_8, sourceFile.getCharset()); myFixture.enableInspections(EditorConfigEncodingInspection.class); IntentionAction quickFix = myFixture.findSingleIntention(EditorConfigBundle.message("inspection.file.encoding.apply")); assertNotNull(quickFix); myFixture.launchAction(quickFix); assertEquals(StandardCharsets.ISO_8859_1, sourceFile.getCharset()); myFixture.checkHighlighting(); }