From d4b221daf194dc1a186f8a8d04fe146e0ced1d94 Mon Sep 17 00:00:00 2001 From: Anna Kozlova Date: Wed, 15 May 2024 10:17:38 +0200 Subject: [PATCH] IJPL-797 `intellij.platform.smRunner` review internal API GitOrigin-RevId: 0e5b2b895e93fda6321f9676d20beccbdc485640 --- .../{api-dump-unreviewed.txt => api-dump.txt} | 232 +----------------- platform/smRunner/exposed-private-api.txt | 1 - platform/smRunner/exposed-third-party-api.txt | 1 - .../testframework/sm/SmRunnerBundle.java | 6 +- ...eralIdBasedToSMTRunnerEventsConvertor.java | 2 + .../sm/runner/OutputEventSplitter.kt | 2 + .../testframework/sm/runner/ProxyFilters.java | 2 + .../sm/runner/SMTRunnerEventsListener.java | 2 + .../SMTRunnerRunDashboardCustomizer.java | 2 +- .../testframework/sm/runner/SMTestProxy.java | 6 +- .../sm/runner/TestListenerProtocol.kt | 2 +- .../history/ImportTestOutputExtension.java | 2 + .../ImportedTestConsoleProperties.java | 2 + .../history/ImportedTestContentHandler.java | 3 + .../history/ImportedTestRunnableState.java | 2 + .../ImportedToGeneralTestEventsConverter.java | 2 + .../actions/ImportTestsFromFileAction.java | 2 + .../sm/runner/states/package-info.java | 5 + .../sm/runner/ui/SMPoolOfTestIcons.java | 2 + .../sm/runner/ui/SMTRunnerToolbarPanel.java | 41 ---- .../sm/runner/ui/SMTestRunnerResultsForm.java | 33 ++- .../sm/runner/ui/TestStackTraceParser.java | 2 + platform/testRunner/api-dump.txt | 1 - .../testframework/ui/TestResultsPanel.java | 2 + platform/util/base/api-dump.txt | 19 ++ .../smRunner/OutputEventSplitterBase.kt | 12 +- 26 files changed, 95 insertions(+), 293 deletions(-) rename platform/smRunner/{api-dump-unreviewed.txt => api-dump.txt} (76%) delete mode 100644 platform/smRunner/exposed-private-api.txt create mode 100644 platform/smRunner/src/com/intellij/execution/testframework/sm/runner/states/package-info.java delete mode 100644 platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMTRunnerToolbarPanel.java diff --git a/platform/smRunner/api-dump-unreviewed.txt b/platform/smRunner/api-dump.txt similarity index 76% rename from platform/smRunner/api-dump-unreviewed.txt rename to platform/smRunner/api-dump.txt index a7a955f971f9..3f72c876dbe9 100644 --- a/platform/smRunner/api-dump-unreviewed.txt +++ b/platform/smRunner/api-dump.txt @@ -40,9 +40,6 @@ f:com.intellij.execution.testframework.sm.ServiceMessageUtil - s:parse(java.lang.String,Z):jetbrains.buildServer.messages.serviceMessages.ServiceMessage - s:parse(java.lang.String,Z,Z):jetbrains.buildServer.messages.serviceMessages.ServiceMessage - s:parse(java.lang.String,Z,Z,java.lang.String):jetbrains.buildServer.messages.serviceMessages.ServiceMessage -f:com.intellij.execution.testframework.sm.SmRunnerBundle -- s:message(java.lang.String,java.lang.Object[]):java.lang.String -- s:messagePointer(java.lang.String,java.lang.Object[]):java.util.function.Supplier c:com.intellij.execution.testframework.sm.TestHistoryConfiguration - com.intellij.openapi.components.PersistentStateComponent - ():V @@ -65,29 +62,6 @@ c:com.intellij.execution.testframework.sm.TestsLocationProviderUtil$FileInfo - getFile():com.intellij.openapi.vfs.VirtualFile - getProximity():I - processRelativePathComponent(java.lang.String):V -c:com.intellij.execution.testframework.sm.runner.GeneralIdBasedToSMTRunnerEventsConvertor -- com.intellij.execution.testframework.sm.runner.GeneralTestEventsProcessor -- (com.intellij.openapi.project.Project,com.intellij.execution.testframework.sm.runner.SMTestProxy$SMRootTestProxy,java.lang.String):V -- p:createProxy(java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String):com.intellij.execution.testframework.sm.runner.SMTestProxy -- p:createSuite(java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String):com.intellij.execution.testframework.sm.runner.SMTestProxy -- dispose():V -- findProxyById(java.lang.String):com.intellij.execution.testframework.sm.runner.SMTestProxy -- onError(java.lang.String,java.lang.String,java.lang.String,Z):V -- onError(java.lang.String,java.lang.String,Z):V -- onFinishTesting():V -- onSetNodeProperty(com.intellij.execution.testframework.sm.runner.events.TestSetNodePropertyEvent):V -- onStartTesting():V -- onSuiteFinished(com.intellij.execution.testframework.sm.runner.events.TestSuiteFinishedEvent):V -- onSuiteStarted(com.intellij.execution.testframework.sm.runner.events.TestSuiteStartedEvent):V -- onTestFailure(com.intellij.execution.testframework.sm.runner.events.TestFailedEvent):V -- onTestFinished(com.intellij.execution.testframework.sm.runner.events.TestFinishedEvent):V -- onTestIgnored(com.intellij.execution.testframework.sm.runner.events.TestIgnoredEvent):V -- onTestOutput(com.intellij.execution.testframework.sm.runner.events.TestOutputEvent):V -- onTestStarted(com.intellij.execution.testframework.sm.runner.events.TestStartedEvent):V -- onTestsCountInSuite(I):V -- onTestsReporterAttached():V -- onUncapturedOutput(java.lang.String,com.intellij.openapi.util.Key):V -- setPrinterProvider(com.intellij.execution.testframework.sm.runner.TestProxyPrinterProvider):V a:com.intellij.execution.testframework.sm.runner.GeneralTestEventsProcessor - com.intellij.openapi.Disposable - pf:myBuildTreeRunnables:java.util.List @@ -188,7 +162,7 @@ a:com.intellij.execution.testframework.sm.runner.OutputEventSplitter - (Z,Z):V - b:(Z,Z,I,kotlin.jvm.internal.DefaultConstructorMarker):V - a:onTextAvailable(java.lang.String,com.intellij.openapi.util.Key):V -- f:onTextAvailable(java.lang.String,com.intellij.smRunner.OutputEventSplitterBase$OutputType):V +- f:onTextAvailable(java.lang.String,com.intellij.smRunner.OutputType):V - f:process(java.lang.String,com.intellij.openapi.util.Key):V f:com.intellij.execution.testframework.sm.runner.OutputEventSplitter$Companion a:com.intellij.execution.testframework.sm.runner.OutputLineSplitter @@ -223,12 +197,6 @@ com.intellij.execution.testframework.sm.runner.ProcessOutputConsumer - flushBufferOnProcessTermination(I):V - a:process(java.lang.String,com.intellij.openapi.util.Key):V - a:setProcessor(com.intellij.execution.testframework.sm.runner.GeneralTestEventsProcessor):V -com.intellij.execution.testframework.sm.runner.ProxyFilters -- sf:ERROR_LEAF:com.intellij.execution.testframework.Filter -- sf:FAILURE_LEAF:com.intellij.execution.testframework.Filter -- sf:FILTER_ERRORS:com.intellij.execution.testframework.Filter -- sf:FILTER_FAILURES:com.intellij.execution.testframework.Filter -- sf:FILTER_PASSED:com.intellij.execution.testframework.Filter com.intellij.execution.testframework.sm.runner.SMRunnerConsolePropertiesProvider - com.intellij.execution.testframework.actions.ConsolePropertiesProvider - a:createTestConsoleProperties(com.intellij.execution.Executor):com.intellij.execution.testframework.sm.runner.SMTRunnerConsoleProperties @@ -314,11 +282,6 @@ c:com.intellij.execution.testframework.sm.runner.SMTRunnerNodeDescriptor - com.intellij.execution.testframework.ui.BaseTestProxyNodeDescriptor - (com.intellij.openapi.project.Project,com.intellij.execution.testframework.sm.runner.SMTestProxy,com.intellij.ide.util.treeView.NodeDescriptor):V - getWeight():I -c:com.intellij.execution.testframework.sm.runner.SMTRunnerRunDashboardCustomizer -- com.intellij.execution.dashboard.RunDashboardCustomizer -- ():V -- isApplicable(com.intellij.execution.RunnerAndConfigurationSettings,com.intellij.execution.ui.RunContentDescriptor):Z -- updatePresentation(com.intellij.ide.projectView.PresentationData,com.intellij.execution.dashboard.RunDashboardRunConfigurationNode):Z c:com.intellij.execution.testframework.sm.runner.SMTRunnerTreeBuilder - com.intellij.execution.testframework.ui.AbstractTestTreeBuilderBase - com.intellij.openapi.Disposable @@ -370,7 +333,6 @@ c:com.intellij.execution.testframework.sm.runner.SMTestProxy - canNavigateToSource():Z - collectChildren():java.util.List - collectChildren(com.intellij.execution.testframework.Filter):java.util.List -- p:determineSuiteStateOnFinished():com.intellij.execution.testframework.sm.runner.states.AbstractState - dispose():V - getAllTests():java.util.List - getChildren():java.util.List @@ -424,14 +386,12 @@ c:com.intellij.execution.testframework.sm.runner.SMTestProxy - setTerminated():V - setTestComparisonFailed(java.lang.String,java.lang.String,java.lang.String,java.lang.String):V - setTestComparisonFailed(java.lang.String,java.lang.String,java.lang.String,java.lang.String,com.intellij.execution.testframework.sm.runner.events.TestFailedEvent):V -- setTestComparisonFailed(java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String,Z):com.intellij.execution.testframework.sm.runner.states.TestComparisonFailedState - setTestFailed(java.lang.String,java.lang.String,Z):V - setTestIgnored(java.lang.String,java.lang.String):V - setTreeBuildBeforeStart():V - shouldRun():Z - shouldSkipRootNodeForExport():Z - toString():java.lang.String -- updateFailedState(com.intellij.execution.testframework.sm.runner.states.TestFailedState):V - wasLaunched():Z - wasTerminated():Z c:com.intellij.execution.testframework.sm.runner.SMTestProxy$SMRootTestProxy @@ -439,7 +399,6 @@ c:com.intellij.execution.testframework.sm.runner.SMTestProxy$SMRootTestProxy - com.intellij.execution.testframework.TestProxyRoot - ():V - (Z,javax.swing.JComponent):V -- p:determineSuiteStateOnFinished():com.intellij.execution.testframework.sm.runner.states.AbstractState - getComment():java.lang.String - f:getDurationStrategy():com.intellij.execution.testframework.sm.runner.events.TestDurationStrategy - getExecutionId():J @@ -458,9 +417,6 @@ c:com.intellij.execution.testframework.sm.runner.SMTestProxy$SMRootTestProxy - setTestConsoleProperties(com.intellij.execution.testframework.TestConsoleProperties):V - setTestsReporterAttached():V - testingRestarted():V -f:com.intellij.execution.testframework.sm.runner.TestListenerProtocol -- sf:CLASS_CONFIGURATION:java.lang.String -- sf:INSTANCE:com.intellij.execution.testframework.sm.runner.TestListenerProtocol com.intellij.execution.testframework.sm.runner.TestProxyFilterProvider - a:getFilter(java.lang.String,java.lang.String,java.lang.String):com.intellij.execution.filters.Filter f:com.intellij.execution.testframework.sm.runner.TestProxyPrinterProvider @@ -592,40 +548,8 @@ a:com.intellij.execution.testframework.sm.runner.events.TreeNodeEvent - s:getNodeId(jetbrains.buildServer.messages.serviceMessages.ServiceMessage,java.lang.String):java.lang.String - f:toString():java.lang.String com.intellij.execution.testframework.sm.runner.history.ImportTestOutputExtension -- sf:EP_NAME:com.intellij.openapi.extensions.ExtensionPointName - a:createHandler(java.io.Reader,com.intellij.execution.testframework.sm.runner.GeneralTestEventsProcessor):org.xml.sax.helpers.DefaultHandler - s:findHandler(java.util.function.Supplier,com.intellij.execution.testframework.sm.runner.GeneralTestEventsProcessor):org.xml.sax.helpers.DefaultHandler -c:com.intellij.execution.testframework.sm.runner.history.ImportedTestConsoleProperties -- com.intellij.execution.testframework.sm.runner.SMTRunnerConsoleProperties -- com.intellij.execution.testframework.sm.SMCustomMessagesParsing -- (com.intellij.execution.testframework.sm.runner.SMTRunnerConsoleProperties,java.io.File,com.intellij.execution.process.ProcessHandler,com.intellij.openapi.project.Project,com.intellij.execution.configurations.RunProfile,java.lang.String,com.intellij.execution.Executor):V -- addStackTraceFilter(com.intellij.execution.filters.Filter):V -- appendAdditionalActions(com.intellij.openapi.actionSystem.DefaultActionGroup,javax.swing.JComponent,com.intellij.execution.testframework.TestConsoleProperties):V -- createRerunFailedTestsAction(com.intellij.execution.ui.ConsoleView):com.intellij.execution.testframework.actions.AbstractRerunFailedTestsAction -- createTestEventsConverter(java.lang.String,com.intellij.execution.testframework.TestConsoleProperties):com.intellij.execution.testframework.sm.runner.OutputToGeneralTestEventsConverter -- fixEmptySuite():Z -- getErrorNavigatable(com.intellij.execution.Location,java.lang.String):com.intellij.pom.Navigatable -- getFilterProvider():com.intellij.execution.testframework.sm.runner.TestProxyFilterProvider -- getSelectionMode():I -- getTestLocator():com.intellij.execution.testframework.sm.runner.SMTestLocator -- isIdBasedTestTree():Z -- isPrintTestingStartedTime():Z -c:com.intellij.execution.testframework.sm.runner.history.ImportedTestContentHandler -- org.xml.sax.helpers.DefaultHandler -- (com.intellij.execution.testframework.sm.runner.GeneralTestEventsProcessor):V -- characters(C[],I,I):V -- endElement(java.lang.String,java.lang.String,java.lang.String):V -- startElement(java.lang.String,java.lang.String,java.lang.String,org.xml.sax.Attributes):V -c:com.intellij.execution.testframework.sm.runner.history.ImportedTestRunnableState -- com.intellij.execution.configurations.RunProfileState -- com.intellij.execution.testframework.HistoryTestRunnableState -- (com.intellij.execution.testframework.sm.runner.history.actions.AbstractImportTestsAction$ImportRunProfile,java.io.File):V -- execute(com.intellij.execution.Executor,com.intellij.execution.runners.ProgramRunner):com.intellij.execution.ExecutionResult -c:com.intellij.execution.testframework.sm.runner.history.ImportedToGeneralTestEventsConverter -- com.intellij.execution.testframework.sm.runner.OutputToGeneralTestEventsConverter -- (java.lang.String,com.intellij.execution.testframework.TestConsoleProperties,java.io.File,com.intellij.execution.process.ProcessHandler):V -- onStartTesting():V -- s:parseTestResults(java.util.function.Supplier,com.intellij.execution.testframework.sm.runner.GeneralTestEventsProcessor):V a:com.intellij.execution.testframework.sm.runner.history.actions.AbstractImportTestsAction - com.intellij.openapi.actionSystem.AnAction - sf:TEST_HISTORY_SIZE:java.lang.String @@ -649,10 +573,6 @@ c:com.intellij.execution.testframework.sm.runner.history.actions.AbstractImportT - getProject():com.intellij.openapi.project.Project - getState(com.intellij.execution.Executor,com.intellij.execution.runners.ExecutionEnvironment):com.intellij.execution.configurations.RunProfileState - getTarget():com.intellij.execution.ExecutionTarget -c:com.intellij.execution.testframework.sm.runner.history.actions.ImportTestsFromFileAction -- com.intellij.execution.testframework.sm.runner.history.actions.AbstractImportTestsAction -- ():V -- p:getFile(com.intellij.openapi.project.Project):com.intellij.openapi.vfs.VirtualFile c:com.intellij.execution.testframework.sm.runner.history.actions.ImportTestsFromHistoryAction - com.intellij.execution.testframework.sm.runner.history.actions.AbstractImportTestsAction - (com.intellij.openapi.project.Project,java.lang.String):V @@ -664,131 +584,8 @@ c:com.intellij.execution.testframework.sm.runner.history.actions.ImportTestsGrou - (com.intellij.execution.testframework.sm.runner.SMTRunnerConsoleProperties):V - getActionUpdateThread():com.intellij.openapi.actionSystem.ActionUpdateThread - getChildren(com.intellij.openapi.actionSystem.AnActionEvent):com.intellij.openapi.actionSystem.AnAction[] -a:com.intellij.execution.testframework.sm.runner.states.AbstractState -- com.intellij.execution.testframework.Printable -- com.intellij.execution.testframework.sm.runner.states.TestStateInfo -- ():V -- printOn(com.intellij.execution.testframework.Printer):V -c:com.intellij.execution.testframework.sm.runner.states.CompoundTestFailedState -- com.intellij.execution.testframework.sm.runner.states.TestFailedState -- ():V -- addFailure(com.intellij.execution.testframework.sm.runner.states.TestFailedState):V -- getHyperlinks():java.util.List -- printOn(com.intellij.execution.testframework.Printer):V -f:com.intellij.execution.testframework.sm.runner.states.NotRunState -- com.intellij.execution.testframework.sm.runner.states.AbstractState -- s:getInstance():com.intellij.execution.testframework.sm.runner.states.NotRunState -- getMagnitude():com.intellij.execution.testframework.sm.runner.states.TestStateInfo$Magnitude -- isDefect():Z -- isFinal():Z -- isInProgress():Z -- toString():java.lang.String -- wasLaunched():Z -- wasTerminated():Z -a:com.intellij.execution.testframework.sm.runner.states.SuiteFinishedState -- com.intellij.execution.testframework.sm.runner.states.AbstractState -- s:EMPTY_SUITE:com.intellij.execution.testframework.sm.runner.states.SuiteFinishedState -- s:ERROR_SUITE:com.intellij.execution.testframework.sm.runner.states.SuiteFinishedState -- s:FAILED_SUITE:com.intellij.execution.testframework.sm.runner.states.SuiteFinishedState -- s:PASSED_SUITE:com.intellij.execution.testframework.sm.runner.states.SuiteFinishedState -- s:TESTS_REPORTER_NOT_ATTACHED:com.intellij.execution.testframework.sm.runner.states.SuiteFinishedState -- s:WITH_IGNORED_TESTS_SUITE:com.intellij.execution.testframework.sm.runner.states.SuiteFinishedState -- isDefect():Z -- isFinal():Z -- isInProgress():Z -- wasLaunched():Z -- wasTerminated():Z -c:com.intellij.execution.testframework.sm.runner.states.SuiteInProgressState -- com.intellij.execution.testframework.sm.runner.states.TestInProgressState -- (com.intellij.execution.testframework.sm.runner.SMTestProxy):V -- isDefect():Z -- toString():java.lang.String -c:com.intellij.execution.testframework.sm.runner.states.TerminatedState -- com.intellij.execution.testframework.sm.runner.states.AbstractState -- sf:INSTANCE:com.intellij.execution.testframework.sm.runner.states.TerminatedState -- p:():V -- getMagnitude():com.intellij.execution.testframework.sm.runner.states.TestStateInfo$Magnitude -- isDefect():Z -- isFinal():Z -- isInProgress():Z -- toString():java.lang.String -- wasLaunched():Z -- wasTerminated():Z -c:com.intellij.execution.testframework.sm.runner.states.TestComparisonFailedState -- com.intellij.execution.testframework.sm.runner.states.TestFailedState -- (java.lang.String,java.lang.String,java.lang.String,java.lang.String,Z,java.lang.String,java.lang.String):V -- dispose():V -- getHyperlink():com.intellij.execution.testframework.stacktrace.DiffHyperlink -- printOn(com.intellij.execution.testframework.Printer):V -- setToDeleteActualFile(Z):V -- setToDeleteExpectedFile(Z):V -c:com.intellij.execution.testframework.sm.runner.states.TestErrorState -- com.intellij.execution.testframework.sm.runner.states.TestFailedState -- (java.lang.String,java.lang.String):V -- getMagnitude():com.intellij.execution.testframework.sm.runner.states.TestStateInfo$Magnitude -- toString():java.lang.String -c:com.intellij.execution.testframework.sm.runner.states.TestFailedState -- com.intellij.execution.testframework.sm.runner.states.AbstractState -- com.intellij.openapi.Disposable -- (java.lang.String,java.lang.String):V -- s:buildErrorPresentationText(java.lang.String,java.lang.String):java.lang.String -- dispose():V -- p:getErrorMsgPresentation():java.lang.String -- getMagnitude():com.intellij.execution.testframework.sm.runner.states.TestStateInfo$Magnitude -- p:getStacktracePresentation():java.lang.String -- isDefect():Z -- isFinal():Z -- isInProgress():Z -- printOn(com.intellij.execution.testframework.Printer):V -- toString():java.lang.String -- wasLaunched():Z -- wasTerminated():Z -c:com.intellij.execution.testframework.sm.runner.states.TestIgnoredState -- com.intellij.execution.testframework.sm.runner.states.AbstractState -- (java.lang.String,java.lang.String):V -- getMagnitude():com.intellij.execution.testframework.sm.runner.states.TestStateInfo$Magnitude -- isDefect():Z -- isFinal():Z -- isInProgress():Z -- printOn(com.intellij.execution.testframework.Printer):V -- toString():java.lang.String -- wasLaunched():Z -- wasTerminated():Z -c:com.intellij.execution.testframework.sm.runner.states.TestInProgressState -- com.intellij.execution.testframework.sm.runner.states.AbstractState -- sf:TEST:com.intellij.execution.testframework.sm.runner.states.TestInProgressState -- p:():V -- getMagnitude():com.intellij.execution.testframework.sm.runner.states.TestStateInfo$Magnitude -- isDefect():Z -- isFinal():Z -- isInProgress():Z -- toString():java.lang.String -- wasLaunched():Z -- wasTerminated():Z -f:com.intellij.execution.testframework.sm.runner.states.TestPassedState -- com.intellij.execution.testframework.sm.runner.states.AbstractState -- sf:INSTANCE:com.intellij.execution.testframework.sm.runner.states.TestPassedState -- getMagnitude():com.intellij.execution.testframework.sm.runner.states.TestStateInfo$Magnitude -- isDefect():Z -- isFinal():Z -- isInProgress():Z -- toString():java.lang.String -- wasLaunched():Z -- wasTerminated():Z com.intellij.execution.testframework.sm.runner.ui.AttachToProcessListener - a:onAttachToProcess(com.intellij.execution.process.ProcessHandler):V -f:com.intellij.execution.testframework.sm.runner.ui.SMPoolOfTestIcons -- com.intellij.execution.testframework.PoolOfTestIcons -- sf:FAILED_E_ICON:javax.swing.Icon -- sf:IGNORED_E_ICON:javax.swing.Icon -- sf:PASSED_E_ICON:javax.swing.Icon -- sf:PAUSED_E_ICON:javax.swing.Icon -- sf:RUNNING_E_ICON:javax.swing.Icon -- sf:RUNNING_ICON:javax.swing.Icon -- sf:SKIPPED_E_ICON:javax.swing.Icon -- sf:TERMINATED_E_ICON:javax.swing.Icon -- ():V -- s:addErrorMarkTo(javax.swing.Icon):javax.swing.Icon com.intellij.execution.testframework.sm.runner.ui.SMRootTestProxyFormatter - a:format(com.intellij.execution.testframework.sm.runner.SMTestProxy$SMRootTestProxy,com.intellij.execution.testframework.sm.runner.ui.TestTreeRenderer):V c:com.intellij.execution.testframework.sm.runner.ui.SMTRunnerConsoleView @@ -819,10 +616,6 @@ c:com.intellij.execution.testframework.sm.runner.ui.SMTRunnerTestTreeView - s:getTestProxyFor(java.lang.Object):com.intellij.execution.testframework.sm.runner.SMTestProxy - *:setAccessibleStatus(java.lang.String):V - setTestResultsViewer(com.intellij.execution.testframework.sm.runner.ui.TestResultsViewer):V -c:com.intellij.execution.testframework.sm.runner.ui.SMTRunnerToolbarPanel -- com.intellij.execution.testframework.ToolbarPanel -- (com.intellij.execution.testframework.TestConsoleProperties,com.intellij.execution.testframework.TestFrameworkRunningModel,javax.swing.JComponent):V -- setModel(com.intellij.execution.testframework.TestFrameworkRunningModel):V c:com.intellij.execution.testframework.sm.runner.ui.SMTRunnerUIActionsHandler - com.intellij.execution.testframework.sm.runner.ui.TestResultsViewer$EventsListener - (com.intellij.execution.testframework.TestConsoleProperties):V @@ -833,46 +626,24 @@ c:com.intellij.execution.testframework.sm.runner.ui.SMTestRunnerResultsForm - com.intellij.execution.testframework.sm.runner.SMTRunnerEventsListener - com.intellij.execution.testframework.sm.runner.ui.TestResultsViewer - sf:HISTORY_DATE_FORMAT:java.lang.String -- (com.intellij.execution.ui.ConsoleView,com.intellij.execution.testframework.TestConsoleProperties,java.lang.String):V - addEventsListener(com.intellij.execution.testframework.sm.runner.ui.TestResultsViewer$EventsListener):V - addTestsTreeSelectionListener(javax.swing.event.TreeSelectionListener):V -- p:createTestTreeView():javax.swing.JComponent -- p:createToolbarPanel():com.intellij.execution.testframework.ToolbarPanel - dispose():V - p:getEndTime():J - getFailedTestCount():I - getFinishedTestCount():I -- getHistoryFileName():java.lang.String - getIgnoredTestCount():I -- getMentionedCategories():java.util.Set - getProperties():com.intellij.execution.testframework.TestConsoleProperties - getRoot():com.intellij.execution.testframework.AbstractTestProxy - p:getStartTime():J - p:getStartedTestCount():I - getTestsRootNode():com.intellij.execution.testframework.sm.runner.SMTestProxy$SMRootTestProxy -- getTestsStatusColor():java.awt.Color - p:getTotalTestCount():I - getTreeBuilder():com.intellij.execution.testframework.sm.runner.SMTRunnerTreeBuilder - getTreeView():com.intellij.execution.testframework.TestTreeView - hasTestSuites():Z - p:hideToolbar():V - isRunning():Z -- onCustomProgressTestFailed():V -- onCustomProgressTestFinished():V -- onCustomProgressTestStarted():V -- onCustomProgressTestsCategory(java.lang.String,I):V -- onSuiteFinished(com.intellij.execution.testframework.sm.runner.SMTestProxy):V -- onSuiteStarted(com.intellij.execution.testframework.sm.runner.SMTestProxy):V -- onSuiteTreeNodeAdded(com.intellij.execution.testframework.sm.runner.SMTestProxy):V -- onSuiteTreeStarted(com.intellij.execution.testframework.sm.runner.SMTestProxy):V -- onTestFailed(com.intellij.execution.testframework.sm.runner.SMTestProxy):V -- onTestFinished(com.intellij.execution.testframework.sm.runner.SMTestProxy):V -- onTestIgnored(com.intellij.execution.testframework.sm.runner.SMTestProxy):V -- onTestStarted(com.intellij.execution.testframework.sm.runner.SMTestProxy):V -- onTestingFinished(com.intellij.execution.testframework.sm.runner.SMTestProxy$SMRootTestProxy):V -- onTestingStarted(com.intellij.execution.testframework.sm.runner.SMTestProxy$SMRootTestProxy):V -- onTestsCountInSuite(I):V -- performUpdate():V - selectAndNotify(com.intellij.execution.testframework.AbstractTestProxy):V - setFilter(com.intellij.execution.testframework.Filter):V com.intellij.execution.testframework.sm.runner.ui.TestProxyTreeSelectionListener @@ -890,7 +661,6 @@ com.intellij.execution.testframework.sm.runner.ui.TestResultsViewer$EventsListen - onTestingStarted(com.intellij.execution.testframework.sm.runner.ui.TestResultsViewer):V c:com.intellij.execution.testframework.sm.runner.ui.TestStackTraceParser - p:(I,java.lang.String,java.lang.String,java.lang.String):V -- (java.lang.String,java.lang.String,java.lang.String,com.intellij.execution.testframework.sm.runner.SMTestLocator,com.intellij.openapi.project.Project):V - getErrorMessage():java.lang.String - getFailedLine():I - getFailedMethodName():java.lang.String diff --git a/platform/smRunner/exposed-private-api.txt b/platform/smRunner/exposed-private-api.txt deleted file mode 100644 index 608d9b813e9d..000000000000 --- a/platform/smRunner/exposed-private-api.txt +++ /dev/null @@ -1 +0,0 @@ -com/intellij/smRunner/OutputEventSplitterBase$OutputType diff --git a/platform/smRunner/exposed-third-party-api.txt b/platform/smRunner/exposed-third-party-api.txt index f331e59c9042..a786f83e0b38 100644 --- a/platform/smRunner/exposed-third-party-api.txt +++ b/platform/smRunner/exposed-third-party-api.txt @@ -9,5 +9,4 @@ jetbrains/buildServer/messages/serviceMessages/TestStarted jetbrains/buildServer/messages/serviceMessages/TestSuiteFinished jetbrains/buildServer/messages/serviceMessages/TestSuiteStarted kotlin/jvm/internal/DefaultConstructorMarker -org/xml/sax/Attributes org/xml/sax/helpers/DefaultHandler diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/SmRunnerBundle.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/SmRunnerBundle.java index 59eee59bf679..875ccc23d6d5 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/SmRunnerBundle.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/SmRunnerBundle.java @@ -2,13 +2,11 @@ package com.intellij.execution.testframework.sm; import com.intellij.DynamicBundle; -import org.jetbrains.annotations.Nls; -import org.jetbrains.annotations.NonNls; -import org.jetbrains.annotations.NotNull; -import org.jetbrains.annotations.PropertyKey; +import org.jetbrains.annotations.*; import java.util.function.Supplier; +@ApiStatus.Internal public final class SmRunnerBundle { private static final @NonNls String BUNDLE = "messages.SmRunnerBundle"; private static final DynamicBundle INSTANCE = new DynamicBundle(SmRunnerBundle.class, BUNDLE); diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/GeneralIdBasedToSMTRunnerEventsConvertor.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/GeneralIdBasedToSMTRunnerEventsConvertor.java index 3a3d0aff31ac..0ac553a152c2 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/GeneralIdBasedToSMTRunnerEventsConvertor.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/GeneralIdBasedToSMTRunnerEventsConvertor.java @@ -9,6 +9,7 @@ import com.intellij.openapi.application.ApplicationManager; import com.intellij.openapi.diagnostic.Logger; import com.intellij.openapi.project.Project; import com.intellij.openapi.util.Key; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -19,6 +20,7 @@ import java.util.concurrent.ConcurrentHashMap; import static com.intellij.execution.testframework.sm.runner.events.TestSetNodePropertyEvent.NodePropertyKey.PRESENTABLE_NAME; +@ApiStatus.Internal public class GeneralIdBasedToSMTRunnerEventsConvertor extends GeneralTestEventsProcessor { private static final Logger LOG = Logger.getInstance(GeneralIdBasedToSMTRunnerEventsConvertor.class); diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/OutputEventSplitter.kt b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/OutputEventSplitter.kt index 4226dfe15cb9..fb597e9ba3f5 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/OutputEventSplitter.kt +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/OutputEventSplitter.kt @@ -6,6 +6,8 @@ import com.intellij.execution.process.ProcessOutputType import com.intellij.execution.process.ProcessOutputTypes import com.intellij.openapi.util.Key import com.intellij.smRunner.OutputEventSplitterBase +import com.intellij.smRunner.OutputStreamType +import com.intellij.smRunner.OutputType import jetbrains.buildServer.messages.serviceMessages.ServiceMessage /** diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ProxyFilters.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ProxyFilters.java index 6249a4ef8659..d958235e1d05 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ProxyFilters.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ProxyFilters.java @@ -18,10 +18,12 @@ package com.intellij.execution.testframework.sm.runner; import com.intellij.execution.testframework.AbstractTestProxy; import com.intellij.execution.testframework.Filter; import com.intellij.execution.testframework.sm.runner.states.TestStateInfo; +import org.jetbrains.annotations.ApiStatus; /** * @author Roman Chernyatchik */ +@ApiStatus.Internal public interface ProxyFilters { Filter FILTER_PASSED = new Filter() { @Override diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTRunnerEventsListener.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTRunnerEventsListener.java index 095aff22f666..b4e0534f2d1d 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTRunnerEventsListener.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTRunnerEventsListener.java @@ -5,12 +5,14 @@ import com.intellij.execution.testframework.sm.runner.events.TestOutputEvent; import com.intellij.execution.testframework.sm.runner.events.TestSetNodePropertyEvent; import com.intellij.openapi.util.Key; import com.intellij.util.messages.Topic; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; /** * Handles Test Runner events. */ +@ApiStatus.OverrideOnly public interface SMTRunnerEventsListener { @Topic.ProjectLevel diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTRunnerRunDashboardCustomizer.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTRunnerRunDashboardCustomizer.java index f901e69e7465..3890924d7c89 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTRunnerRunDashboardCustomizer.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTRunnerRunDashboardCustomizer.java @@ -23,7 +23,7 @@ import org.jetbrains.annotations.Nullable; import java.lang.ref.WeakReference; -public class SMTRunnerRunDashboardCustomizer extends RunDashboardCustomizer { +class SMTRunnerRunDashboardCustomizer extends RunDashboardCustomizer { private static final SimpleTextAttributes IGNORE_ATTRIBUTES = new SimpleTextAttributes(SimpleTextAttributes.STYLE_PLAIN, ColorProgressBar.YELLOW); private static final SimpleTextAttributes ERROR_ATTRIBUTES = diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTestProxy.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTestProxy.java index 02ef97ab8071..183d8b956cb2 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTestProxy.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/SMTestProxy.java @@ -36,6 +36,7 @@ import com.intellij.psi.util.CachedValuesManager; import com.intellij.util.concurrency.AppExecutorUtil; import com.intellij.util.concurrency.annotations.RequiresEdt; import com.intellij.util.containers.ContainerUtil; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -539,7 +540,7 @@ public class SMTestProxy extends AbstractTestProxy implements Navigatable { fireOnNewPrintable(failedState); } - public void updateFailedState(TestFailedState failedState) { + private void updateFailedState(TestFailedState failedState) { if (myState instanceof CompoundTestFailedState) { ((CompoundTestFailedState)myState).addFailure(failedState); } @@ -579,6 +580,7 @@ public class SMTestProxy extends AbstractTestProxy implements Navigatable { comparisonFailedState.setToDeleteActualFile(event.isActualFileTemp()); } + @ApiStatus.Internal public TestComparisonFailedState setTestComparisonFailed( @Nullable final String localizedMessage, @Nullable final String stackTrace, @@ -869,6 +871,7 @@ public class SMTestProxy extends AbstractTestProxy implements Navigatable { * * @return New state */ + @ApiStatus.Internal protected AbstractState determineSuiteStateOnFinished() { final AbstractState state; if (isLeaf()) { @@ -1088,6 +1091,7 @@ public class SMTestProxy extends AbstractTestProxy implements Navigatable { myHandler = handler; } + @ApiStatus.Internal @Override protected AbstractState determineSuiteStateOnFinished() { if (isLeaf() && !isTestsReporterAttached()) { diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/TestListenerProtocol.kt b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/TestListenerProtocol.kt index dbb6c4fefbfe..894ca606c633 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/TestListenerProtocol.kt +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/TestListenerProtocol.kt @@ -1,7 +1,7 @@ // Copyright 2000-2021 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file. package com.intellij.execution.testframework.sm.runner -object TestListenerProtocol { +internal object TestListenerProtocol { /** * The same constant as com.intellij.rt.execution.TestListenerProtocol.CLASS_CONFIGURATION */ diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportTestOutputExtension.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportTestOutputExtension.java index 540cb22316d6..b65dc89191ea 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportTestOutputExtension.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportTestOutputExtension.java @@ -3,6 +3,7 @@ package com.intellij.execution.testframework.sm.runner.history; import com.intellij.execution.testframework.sm.runner.GeneralTestEventsProcessor; import com.intellij.openapi.extensions.ExtensionPointName; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; import org.xml.sax.helpers.DefaultHandler; @@ -15,6 +16,7 @@ import java.util.function.Supplier; * Extension to import test output from xml file, e.g. generated by ant task */ public interface ImportTestOutputExtension { + @ApiStatus.Internal ExtensionPointName EP_NAME = ExtensionPointName.create("com.intellij.importTestOutput"); /** diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestConsoleProperties.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestConsoleProperties.java index 3ac71a8e9ae2..32ede8e9fa9d 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestConsoleProperties.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestConsoleProperties.java @@ -31,12 +31,14 @@ import com.intellij.execution.ui.ConsoleView; import com.intellij.openapi.actionSystem.DefaultActionGroup; import com.intellij.openapi.project.Project; import com.intellij.pom.Navigatable; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; import javax.swing.*; import java.io.File; +@ApiStatus.Internal public class ImportedTestConsoleProperties extends SMTRunnerConsoleProperties implements SMCustomMessagesParsing { private final @Nullable SMTRunnerConsoleProperties myProperties; private final File myFile; diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestContentHandler.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestContentHandler.java index d886f9040ed9..cba7dbe9815f 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestContentHandler.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestContentHandler.java @@ -14,11 +14,14 @@ import com.intellij.execution.testframework.sm.runner.events.TestSuiteStartedEve import com.intellij.openapi.util.text.StringUtil; import com.intellij.util.containers.Stack; import java.util.Objects; + +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import org.xml.sax.Attributes; import org.xml.sax.SAXException; import org.xml.sax.helpers.DefaultHandler; +@ApiStatus.Internal public class ImportedTestContentHandler extends DefaultHandler { private final GeneralTestEventsProcessor myProcessor; private final Stack mySuites = new Stack<>(); diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestRunnableState.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestRunnableState.java index 1e227029c8e9..c2a1c388e0e2 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestRunnableState.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedTestRunnableState.java @@ -19,6 +19,7 @@ import com.intellij.execution.testframework.sm.runner.SMTRunnerConsoleProperties import com.intellij.execution.testframework.sm.runner.history.actions.AbstractImportTestsAction; import com.intellij.execution.testframework.ui.BaseTestsOutputConsoleView; import com.intellij.openapi.util.Disposer; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -26,6 +27,7 @@ import javax.swing.*; import java.io.File; import java.io.OutputStream; +@ApiStatus.Internal public class ImportedTestRunnableState implements RunProfileState, HistoryTestRunnableState { private final AbstractImportTestsAction.ImportRunProfile myRunProfile; private final File myFile; diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedToGeneralTestEventsConverter.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedToGeneralTestEventsConverter.java index e9854361c1c3..0e4d94b618ef 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedToGeneralTestEventsConverter.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/ImportedToGeneralTestEventsConverter.java @@ -8,6 +8,7 @@ import com.intellij.execution.testframework.sm.runner.GeneralTestEventsProcessor import com.intellij.execution.testframework.sm.runner.OutputToGeneralTestEventsConverter; import com.intellij.openapi.application.ApplicationManager; import com.intellij.openapi.ui.Messages; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import org.xml.sax.InputSource; import org.xml.sax.SAXException; @@ -19,6 +20,7 @@ import java.io.*; import java.nio.charset.StandardCharsets; import java.util.function.Supplier; +@ApiStatus.Internal public class ImportedToGeneralTestEventsConverter extends OutputToGeneralTestEventsConverter { @NotNull private final TestConsoleProperties myConsoleProperties; diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/actions/ImportTestsFromFileAction.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/actions/ImportTestsFromFileAction.java index c1f937cae828..68dce105bad9 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/actions/ImportTestsFromFileAction.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/history/actions/ImportTestsFromFileAction.java @@ -11,9 +11,11 @@ import com.intellij.openapi.fileTypes.StdFileTypes; import com.intellij.openapi.project.Project; import com.intellij.openapi.ui.Messages; import com.intellij.openapi.vfs.VirtualFile; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; +@ApiStatus.Internal public class ImportTestsFromFileAction extends AbstractImportTestsAction { public ImportTestsFromFileAction() { super(SmRunnerBundle.message("sm.test.runner.import.test"), diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/states/package-info.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/states/package-info.java new file mode 100644 index 000000000000..c99b1787b017 --- /dev/null +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/states/package-info.java @@ -0,0 +1,5 @@ +// Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. +@ApiStatus.Internal +package com.intellij.execution.testframework.sm.runner.states; + +import org.jetbrains.annotations.ApiStatus; \ No newline at end of file diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMPoolOfTestIcons.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMPoolOfTestIcons.java index d91ee181324b..76aab91a8ef2 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMPoolOfTestIcons.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMPoolOfTestIcons.java @@ -5,6 +5,7 @@ import com.intellij.execution.testframework.PoolOfTestIcons; import com.intellij.icons.AllIcons; import com.intellij.ui.AnimatedIcon; import com.intellij.ui.LayeredIcon; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NotNull; import javax.swing.*; @@ -12,6 +13,7 @@ import javax.swing.*; /** * @author Roman.Chernyatchik */ +@ApiStatus.Internal public final class SMPoolOfTestIcons implements PoolOfTestIcons { // Error flag icon diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMTRunnerToolbarPanel.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMTRunnerToolbarPanel.java deleted file mode 100644 index be07c78ccc6a..000000000000 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMTRunnerToolbarPanel.java +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright 2000-2009 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.intellij.execution.testframework.sm.runner.ui; - -import com.intellij.execution.testframework.TestConsoleProperties; -import com.intellij.execution.testframework.TestFrameworkRunningModel; -import com.intellij.execution.testframework.ToolbarPanel; - -import javax.swing.*; - -/** - * @author Roman Chernyatchik - */ -public class SMTRunnerToolbarPanel extends ToolbarPanel { - public SMTRunnerToolbarPanel(final TestConsoleProperties properties, - final TestFrameworkRunningModel model, JComponent contentPane) { - super(properties, contentPane); - //TODO rerun failed test - //TODO coverage - setModel(model); - } - - @Override - public void setModel(final TestFrameworkRunningModel model) { - //TODO: RunningTestTracker - for tracking current test - super.setModel(model); - } -} diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMTestRunnerResultsForm.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMTestRunnerResultsForm.java index 146670c3ca98..9c0af600aef3 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMTestRunnerResultsForm.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/SMTestRunnerResultsForm.java @@ -55,10 +55,7 @@ import com.intellij.util.containers.ContainerUtil; import com.intellij.util.text.DateFormatUtil; import com.intellij.util.ui.UIUtil; import com.intellij.util.ui.update.Update; -import org.jetbrains.annotations.ApiStatus; -import org.jetbrains.annotations.NonNls; -import org.jetbrains.annotations.NotNull; -import org.jetbrains.annotations.Nullable; +import org.jetbrains.annotations.*; import javax.swing.*; import javax.swing.border.CompoundBorder; @@ -123,6 +120,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel private final String myHistoryFileName; + @ApiStatus.Internal public SMTestRunnerResultsForm(@NotNull ConsoleView consoleView, @NotNull TestConsoleProperties consoleProperties, @Nullable String splitterPropertyName) { @@ -149,11 +147,15 @@ public class SMTestRunnerResultsForm extends TestResultsPanel new SimpleDateFormat(HISTORY_DATE_FORMAT).format(new Date()); } + @ApiStatus.Internal @Override protected ToolbarPanel createToolbarPanel() { - return new SMTRunnerToolbarPanel(myProperties, this, this); + ToolbarPanel toolbarPanel = new ToolbarPanel(myProperties, this); + toolbarPanel.setModel(this); + return toolbarPanel; } + @ApiStatus.Internal @Override protected JComponent createTestTreeView() { myTreeView = new SMTRunnerTestTreeView(); @@ -202,6 +204,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel * Returns root node, fake parent suite for all tests and suites * */ + @ApiStatus.Internal @Override public void onTestingStarted(@NotNull SMTestProxy.SMRootTestProxy testsRoot) { myTotalTestCount = 0; @@ -251,6 +254,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel } } + @ApiStatus.Internal @Override public void onTestingFinished(@NotNull SMTestProxy.SMRootTestProxy testsRoot) { myEndTime = System.currentTimeMillis(); @@ -321,6 +325,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel } } + @ApiStatus.Internal @Override public void onTestsCountInSuite(final int count) { updateCountersAndProgressOnTestCount(count, false); @@ -332,6 +337,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel * * @param testProxy Proxy */ + @ApiStatus.Internal @Override public void onTestStarted(@NotNull final SMTestProxy testProxy) { if (!testProxy.isConfig() && !TestListenerProtocol.CLASS_CONFIGURATION.equals(testProxy.getName())) { @@ -341,6 +347,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel fireOnTestNodeAdded(testProxy); } + @ApiStatus.Internal @Override public void onSuiteTreeNodeAdded(SMTestProxy testProxy) { if (!testProxy.isSuite()) { @@ -348,10 +355,12 @@ public class SMTestRunnerResultsForm extends TestResultsPanel } } + @ApiStatus.Internal @Override public void onSuiteTreeStarted(SMTestProxy suite) { } + @ApiStatus.Internal @Override public void onTestFailed(@NotNull final SMTestProxy test) { if (Comparing.equal(test, myLastFailed)) return; @@ -375,6 +384,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel } } + @ApiStatus.Internal @Override public void onTestIgnored(@NotNull final SMTestProxy test) { updateOnTestIgnored(test); @@ -387,32 +397,38 @@ public class SMTestRunnerResultsForm extends TestResultsPanel * * @param newSuite Tests suite */ + @ApiStatus.Internal @Override public void onSuiteStarted(@NotNull final SMTestProxy newSuite) { _addTestOrSuite(newSuite); } + @ApiStatus.Internal @Override public void onCustomProgressTestsCategory(@Nullable String categoryName, int testCount) { myCurrentCustomProgressCategory = categoryName; updateCountersAndProgressOnTestCount(testCount, true); } + @ApiStatus.Internal @Override public void onCustomProgressTestStarted() { updateOnTestStarted(true); } + @ApiStatus.Internal @Override public void onCustomProgressTestFailed() { updateOnTestFailed(true); } + @ApiStatus.Internal @Override public void onCustomProgressTestFinished() { updateOnTestFinished(true); } + @ApiStatus.Internal @Override public void onTestFinished(@NotNull final SMTestProxy test) { if (!test.isConfig()) { @@ -421,6 +437,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel updateIconProgress(false); } + @ApiStatus.Internal @Override public void onSuiteFinished(@NotNull final SMTestProxy suite) { //Do nothing @@ -545,10 +562,12 @@ public class SMTestRunnerResultsForm extends TestResultsPanel return myIgnoredTestCount; } + @ApiStatus.Internal public Color getTestsStatusColor() { return myStatusLine.getStatusColor(); } + @ApiStatus.Internal public Set getMentionedCategories() { return myMentionedCategories; } @@ -677,6 +696,7 @@ public class SMTestRunnerResultsForm extends TestResultsPanel /** * for java unit tests */ + @ApiStatus.Internal public void performUpdate() { myTreeBuilder.updateFromRoot(); } @@ -773,12 +793,15 @@ public class SMTestRunnerResultsForm extends TestResultsPanel myStatusLine.setWarning(SmRunnerBundle.message("suffix.incomplete.index.was.used")); } + @ApiStatus.Internal public String getHistoryFileName() { return myHistoryFileName; } + @ApiStatus.Internal AnAction[] getToolbarActions() { return myToolbarPanel.getActionsToMerge(); } + @ApiStatus.Internal AnAction[] getAdditionalToolbarActions() { return myToolbarPanel.getAdditionalActionsToMerge(); } diff --git a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/TestStackTraceParser.java b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/TestStackTraceParser.java index 4f3008392e7f..e2b27aa3b98a 100644 --- a/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/TestStackTraceParser.java +++ b/platform/smRunner/src/com/intellij/execution/testframework/sm/runner/ui/TestStackTraceParser.java @@ -6,6 +6,7 @@ import com.intellij.execution.testframework.sm.runner.SMTestLocator; import com.intellij.openapi.project.Project; import com.intellij.openapi.util.text.StringUtil; import com.intellij.psi.search.GlobalSearchScope; +import org.jetbrains.annotations.ApiStatus; import java.io.BufferedReader; import java.io.IOException; @@ -47,6 +48,7 @@ public class TestStackTraceParser { myTopLocationLine = topLocationLine; } + @ApiStatus.Internal public TestStackTraceParser(String url, String stacktrace, String errorMessage, diff --git a/platform/testRunner/api-dump.txt b/platform/testRunner/api-dump.txt index 818703e7e965..476896edcca4 100644 --- a/platform/testRunner/api-dump.txt +++ b/platform/testRunner/api-dump.txt @@ -449,7 +449,6 @@ a:com.intellij.execution.testframework.ui.TestResultsPanel - ps:createSplitter(java.lang.String,F,Z):com.intellij.ui.JBSplitter - p:createStatusLine():com.intellij.execution.testframework.ui.TestStatusLine - pa:createTestTreeView():javax.swing.JComponent -- p:createToolbarPanel():com.intellij.execution.testframework.ToolbarPanel - dispose():V - getData(java.lang.String):java.lang.Object - getStatusLine():com.intellij.execution.testframework.ui.TestStatusLine diff --git a/platform/testRunner/src/com/intellij/execution/testframework/ui/TestResultsPanel.java b/platform/testRunner/src/com/intellij/execution/testframework/ui/TestResultsPanel.java index 12889bc6151c..9ff092c26259 100644 --- a/platform/testRunner/src/com/intellij/execution/testframework/ui/TestResultsPanel.java +++ b/platform/testRunner/src/com/intellij/execution/testframework/ui/TestResultsPanel.java @@ -17,6 +17,7 @@ import com.intellij.ui.*; import com.intellij.ui.components.panels.NonOpaquePanel; import com.intellij.util.ui.JBUI; import com.intellij.util.ui.UIUtil; +import org.jetbrains.annotations.ApiStatus; import org.jetbrains.annotations.NonNls; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -130,6 +131,7 @@ public abstract class TestResultsPanel extends JPanel implements Disposable, Dat return splitVertically; } + @ApiStatus.Internal protected ToolbarPanel createToolbarPanel() { return new ToolbarPanel(myProperties, this); } diff --git a/platform/util/base/api-dump.txt b/platform/util/base/api-dump.txt index 8ffbef954cda..669cd27da206 100644 --- a/platform/util/base/api-dump.txt +++ b/platform/util/base/api-dump.txt @@ -193,6 +193,25 @@ c:com.intellij.reference.SoftReference - (java.lang.Object,java.lang.ref.ReferenceQueue):V - s:deref(java.util.function.Supplier):java.lang.Object - s:dereference(java.lang.ref.Reference):java.lang.Object +e:com.intellij.smRunner.OutputStreamType +- java.lang.Enum +- sf:STDERR:com.intellij.smRunner.OutputStreamType +- sf:STDOUT:com.intellij.smRunner.OutputStreamType +- sf:SYSTEM:com.intellij.smRunner.OutputStreamType +- s:getEntries():kotlin.enums.EnumEntries +- s:valueOf(java.lang.String):com.intellij.smRunner.OutputStreamType +- s:values():com.intellij.smRunner.OutputStreamType[] +f:com.intellij.smRunner.OutputType +- (java.lang.Object,com.intellij.smRunner.OutputStreamType):V +- f:component1():java.lang.Object +- f:component2():com.intellij.smRunner.OutputStreamType +- f:copy(java.lang.Object,com.intellij.smRunner.OutputStreamType):com.intellij.smRunner.OutputType +- bs:copy$default(com.intellij.smRunner.OutputType,java.lang.Object,com.intellij.smRunner.OutputStreamType,I,java.lang.Object):com.intellij.smRunner.OutputType +- equals(java.lang.Object):Z +- f:getData():java.lang.Object +- f:getStreamType():com.intellij.smRunner.OutputStreamType +- hashCode():I +- toString():java.lang.String com.intellij.util.ArrayFactory - a:create(I):java.lang.Object[] f:com.intellij.util.ArrayUtil diff --git a/platform/util/base/src/com/intellij/smRunner/OutputEventSplitterBase.kt b/platform/util/base/src/com/intellij/smRunner/OutputEventSplitterBase.kt index e13031228f5b..d1ceb260d21b 100644 --- a/platform/util/base/src/com/intellij/smRunner/OutputEventSplitterBase.kt +++ b/platform/util/base/src/com/intellij/smRunner/OutputEventSplitterBase.kt @@ -29,17 +29,17 @@ import kotlin.math.min * * If [cutNewLineBeforeServiceMessage] is set, each service message must have "\n" prefix which is cut. */ +data class OutputType(val data: T, val streamType: OutputStreamType) + +enum class OutputStreamType { + STDOUT, STDERR, SYSTEM +} + @Internal abstract class OutputEventSplitterBase(private val serviceMessagePrefix: String, private val bufferTextUntilNewLine: Boolean, private val cutNewLineBeforeServiceMessage: Boolean) { - data class OutputType(val data: T, val streamType: OutputStreamType) - - enum class OutputStreamType { - STDOUT, STDERR, SYSTEM - } - private data class Output(val text: String, val outputType: OutputType) private var newLinePending: String? = null