mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[java-tests] IGQuickFixesTestCase: improve error reporting
GitOrigin-RevId: 178fe6614ba0a1513399915ec7f9e1fbd9969272
This commit is contained in:
committed by
intellij-monorepo-bot
parent
9fd1a47707
commit
9fb2a08303
@@ -10,6 +10,7 @@ import com.intellij.testFramework.TestDataPath;
|
||||
import com.intellij.testFramework.builders.JavaModuleFixtureBuilder;
|
||||
import com.intellij.testFramework.fixtures.JavaCodeInsightFixtureTestCase;
|
||||
import com.intellij.util.ArrayUtilRt;
|
||||
import one.util.streamex.StreamEx;
|
||||
import org.intellij.lang.annotations.Language;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
@@ -90,6 +91,10 @@ public abstract class IGQuickFixesTestCase extends JavaCodeInsightFixtureTestCas
|
||||
protected void doTest(final String testName, final String hint) {
|
||||
myFixture.configureByFile(getRelativePath() + "/" + testName + ".java");
|
||||
IntentionAction action = myFixture.getAvailableIntention(hint);
|
||||
if (action == null) {
|
||||
fail("No action '"+hint+"' found among "+
|
||||
StreamEx.of(myFixture.getAvailableIntentions()).map(IntentionAction::getText).joining(", "));
|
||||
}
|
||||
assertNotNull(action);
|
||||
Path previewPath = Path.of(myFixture.getTestDataPath(), getRelativePath(), testName + ".preview.java");
|
||||
if (Files.exists(previewPath)) {
|
||||
|
||||
Reference in New Issue
Block a user