ExecutionResult (Executor executor, @NotNull ProgramRunner<?> runner) { final MyEmptyProcessHandler handler = new MyEmptyProcessHandler(); final SMTRunnerConsoleProperties properties; final RunProfile configuration; final String frameworkName; RunConfiguration initialConfiguration = myRunProfile.getInitialConfiguration(); if (initialConfiguration instanceof SMRunnerConsolePropertiesProvider) { configuration = initialConfiguration; properties = ((SMRunnerConsolePropertiesProvider)configuration).createTestConsoleProperties(DefaultRunExecutor.getRunExecutorInstance()); frameworkName = properties.getTestFrameworkName(); } else { configuration = myRunProfile; properties = null; frameworkName = "Import Test Results"; } final ImportedTestConsoleProperties consoleProperties = new ImportedTestConsoleProperties(properties, myFile, handler, myRunProfile.getProject(), configuration, frameworkName, executor); if (properties != null) { Disposer.register(consoleProperties, properties); } final BaseTestsOutputConsoleView console = SMTestRunnerConnectionUtil.createConsole(consoleProperties.getTestFrameworkName(), consoleProperties); final JComponent component = console.getComponent(); AbstractRerunFailedTestsAction rerunFailedTestsAction = null; if (component instanceof TestFrameworkRunningModel) { rerunFailedTestsAction = consoleProperties.createRerunFailedTestsAction(console); if (rerunFailedTestsAction != null) { rerunFailedTestsAction.setModelProvider(() -> (TestFrameworkRunningModel)component); } } console.attachToProcess(handler); final DefaultExecutionResult result = new DefaultExecutionResult(console, handler); if (rerunFailedTestsAction != null) { result.setRestartActions(rerunFailedTestsAction); } return result; }