@Override protected boolean preprocessUsages(@NotNull Ref<UsageInfo[]> refUsages) { if (hasFailedConversions()) { if (ApplicationManager.getApplication().isUnitTestMode()) { throw new RuntimeException(StringUtil.join(myLabeler.getFailedConversionsReport(), "\n")); } FailedConversionsDialog dialog = new FailedConversionsDialog(myLabeler.getFailedConversionsReport(), myProject); if (!dialog.showAndGet()) { final int exitCode = dialog.getExitCode(); prepareSuccessful(); if (exitCode == FailedConversionsDialog.VIEW_USAGES_EXIT_CODE) { previewRefactoring(refUsages.get()); } return false; } } prepareSuccessful(); return true; }