Refactor: Use RefactoringErrorHintException to report errors in test mode

This commit is contained in:
Alexey Sedunov
2018-03-02 15:36:30 +03:00
parent df4c80f43a
commit 9761e33110
@@ -293,7 +293,7 @@ public class CodeInsightUtils {
@NotNull String message, @NotNull String title,
@Nullable String helpId
) {
if (ApplicationManager.getApplication().isUnitTestMode()) throw new RuntimeException(message);
if (ApplicationManager.getApplication().isUnitTestMode()) throw new CommonRefactoringUtil.RefactoringErrorHintException(message);
CommonRefactoringUtil.showErrorHint(project, editor, message, title, helpId);
}