diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/assets/BspAssetsExtension.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/assets/BspAssetsExtension.kt index b28fec99b..a514a8124 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/assets/BspAssetsExtension.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/assets/BspAssetsExtension.kt @@ -3,11 +3,12 @@ package org.jetbrains.plugins.bsp.assets import com.intellij.icons.AllIcons import com.intellij.openapi.util.IconLoader import org.jetbrains.plugins.bsp.config.BspPluginIcons -import org.jetbrains.plugins.bsp.flow.open.BuildToolId +import org.jetbrains.plugins.bsp.extension.points.BuildToolId +import org.jetbrains.plugins.bsp.extension.points.bspBuildToolId import javax.swing.Icon public class BspAssetsExtension : BuildToolAssetsExtension { - override val buildToolId: BuildToolId = BuildToolId("bsp") + override val buildToolId: BuildToolId = bspBuildToolId override val presentableName: String = "BSP" diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/assets/BuildToolAssetsExtension.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/assets/BuildToolAssetsExtension.kt index d3e980743..74804af42 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/assets/BuildToolAssetsExtension.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/assets/BuildToolAssetsExtension.kt @@ -1,7 +1,7 @@ package org.jetbrains.plugins.bsp.assets import com.intellij.openapi.extensions.ExtensionPointName -import org.jetbrains.plugins.bsp.flow.open.WithBuildToolId +import org.jetbrains.plugins.bsp.extension.points.WithBuildToolId import javax.swing.Icon public interface BuildToolAssetsExtension : WithBuildToolId { diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/config/PersistentProjectProperties.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/config/PersistentProjectProperties.kt index 11f26cefc..0ed24816f 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/config/PersistentProjectProperties.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/config/PersistentProjectProperties.kt @@ -4,7 +4,7 @@ import com.intellij.ide.util.PropertiesComponent import com.intellij.openapi.project.Project import com.intellij.openapi.vfs.VirtualFile import com.intellij.openapi.vfs.VirtualFileManager -import org.jetbrains.plugins.bsp.flow.open.BuildToolId +import org.jetbrains.plugins.bsp.extension.points.BuildToolId private const val IS_BSP_PROJECT_KEY = "org.jetbrains.bsp.is.bsp.project" @@ -15,18 +15,18 @@ public var Project.isBspProject: Boolean private const val PROJECT_ROOT_DIR_KEY = "org.jetbrains.bsp.project.root.dir" public var Project.rootDir: VirtualFile - get() = properties.getValue(PROJECT_ROOT_DIR_KEY) - ?.let { VirtualFileManager.getInstance().findFileByUrl(it) } - ?: error("$PROJECT_ROOT_DIR_KEY value not set!") + get() = properties.getValueOrThrow(PROJECT_ROOT_DIR_KEY) + .let { VirtualFileManager.getInstance().findFileByUrl(it) ?: error("Cannot find file by url (url: $it)") } set(value) = properties.setValue(PROJECT_ROOT_DIR_KEY, value.url) private const val BUILD_TOOL_ID_KEY = "org.jetbrains.bsp.build.tool.id" public var Project.buildToolId: BuildToolId - get() = properties.getValue(BUILD_TOOL_ID_KEY) - ?.let { BuildToolId(it) } - ?: error("$BUILD_TOOL_ID_KEY value not set!") + get() = BuildToolId(properties.getValueOrThrow(BUILD_TOOL_ID_KEY)) set(value) = properties.setValue(BUILD_TOOL_ID_KEY, value.id) private val Project.properties: PropertiesComponent get() = PropertiesComponent.getInstance(this) + +private fun PropertiesComponent.getValueOrThrow(key: String): String = + getValue(key) ?: error("$key value not set") diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/extension/points/WithBuildToolId.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/extension/points/WithBuildToolId.kt new file mode 100644 index 000000000..0aa654330 --- /dev/null +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/extension/points/WithBuildToolId.kt @@ -0,0 +1,19 @@ +package org.jetbrains.plugins.bsp.extension.points + +import com.intellij.openapi.extensions.ExtensionPointName + +public data class BuildToolId(public val id: String) + +public interface WithBuildToolId { + public val buildToolId: BuildToolId +} + +internal val bspBuildToolId = BuildToolId("bsp") + +internal fun ExtensionPointName.withBuildToolId(buildToolId: BuildToolId): T? = + this.extensions.find { it.buildToolId == buildToolId } + +internal fun ExtensionPointName.withBuildToolIdOrDefault(buildToolId: BuildToolId): T = + this.withBuildToolId(buildToolId) + ?: withBuildToolId(bspBuildToolId) + ?: error("Missing default implementation (BSP) for extension: ${this.javaClass.name}. Something is wrong.") diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/flow/open/BaseBspProjectOpenProcessor.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/flow/open/BaseBspProjectOpenProcessor.kt index 7a35b1103..831abc24c 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/flow/open/BaseBspProjectOpenProcessor.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/flow/open/BaseBspProjectOpenProcessor.kt @@ -13,6 +13,7 @@ import org.jetbrains.magicmetamodel.ProjectDetails import org.jetbrains.plugins.bsp.config.buildToolId import org.jetbrains.plugins.bsp.config.isBspProject import org.jetbrains.plugins.bsp.config.rootDir +import org.jetbrains.plugins.bsp.extension.points.BuildToolId import org.jetbrains.plugins.bsp.services.BspCoroutineService import org.jetbrains.plugins.bsp.services.MagicMetaModelService import java.nio.file.Path diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/flow/open/BspProjectOpenProcessor.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/flow/open/BspProjectOpenProcessor.kt index 9b760d2ef..a4d57c49e 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/flow/open/BspProjectOpenProcessor.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/flow/open/BspProjectOpenProcessor.kt @@ -4,26 +4,13 @@ import com.intellij.openapi.extensions.ExtensionPointName import com.intellij.openapi.vfs.VirtualFile import org.jetbrains.plugins.bsp.config.BspPluginBundle import org.jetbrains.plugins.bsp.config.BspPluginIcons +import org.jetbrains.plugins.bsp.extension.points.BuildToolId +import org.jetbrains.plugins.bsp.extension.points.WithBuildToolId +import org.jetbrains.plugins.bsp.extension.points.bspBuildToolId +import org.jetbrains.plugins.bsp.extension.points.withBuildToolId import org.jetbrains.plugins.bsp.protocol.connection.BspConnectionFilesProvider import javax.swing.Icon -// TODO: move to a better package -public data class BuildToolId(public val id: String) - -// TODO: move to a better package -public interface WithBuildToolId { - public val buildToolId: BuildToolId -} - -// TODO: move to a better package -internal fun ExtensionPointName.withBuildToolId(buildToolId: BuildToolId): T? = - this.extensions.find { it.buildToolId == buildToolId } - -internal fun ExtensionPointName.withBuildToolIdOrDefault(buildToolId: BuildToolId): T = - this.extensions.find { it.buildToolId == buildToolId } - ?: withBuildToolId(BuildToolId("bsp")) - ?: error("Missing default implementation for extension: ${this.javaClass.name}") - public interface BspProjectOpenProcessorExtension : WithBuildToolId { /** * When a project is opened for the first time [com.intellij.projectImport.ProjectOpenProcessor.canOpenProject] @@ -47,7 +34,7 @@ public interface BspProjectOpenProcessorExtension : WithBuildToolId { } } -internal class BspProjectOpenProcessor : BaseBspProjectOpenProcessor(BuildToolId("bsp")) { +internal class BspProjectOpenProcessor : BaseBspProjectOpenProcessor(bspBuildToolId) { override val name: String = BspPluginBundle.message("plugin.name") override val icon: Icon = BspPluginIcons.bsp diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/actions/LoadTargetAction.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/actions/LoadTargetAction.kt index c10e445aa..abe597a4e 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/actions/LoadTargetAction.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/actions/LoadTargetAction.kt @@ -7,7 +7,7 @@ import org.jetbrains.magicmetamodel.impl.workspacemodel.BuildTargetId import org.jetbrains.plugins.bsp.assets.BuildToolAssetsExtension import org.jetbrains.plugins.bsp.config.BspPluginBundle import org.jetbrains.plugins.bsp.config.buildToolId -import org.jetbrains.plugins.bsp.flow.open.withBuildToolIdOrDefault +import org.jetbrains.plugins.bsp.extension.points.withBuildToolIdOrDefault import org.jetbrains.plugins.bsp.services.MagicMetaModelService import org.jetbrains.plugins.bsp.ui.notifications.BspBalloonNotifier diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/configuration/run/BspRunConfigurationType.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/configuration/run/BspRunConfigurationType.kt index dfdbbb4f8..7311a1ea4 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/configuration/run/BspRunConfigurationType.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/configuration/run/BspRunConfigurationType.kt @@ -20,7 +20,7 @@ import com.intellij.openapi.project.Project import org.jetbrains.plugins.bsp.assets.BuildToolAssetsExtension import org.jetbrains.plugins.bsp.config.BspPluginBundle import org.jetbrains.plugins.bsp.config.buildToolId -import org.jetbrains.plugins.bsp.flow.open.withBuildToolIdOrDefault +import org.jetbrains.plugins.bsp.extension.points.withBuildToolIdOrDefault import org.jetbrains.plugins.bsp.server.tasks.RunTargetTask import org.jetbrains.plugins.bsp.ui.configuration.BspProcessHandler import org.jetbrains.plugins.bsp.ui.console.BspConsoleService diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/configuration/test/BspTestRunConfigurationType.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/configuration/test/BspTestRunConfigurationType.kt index 35dae9e03..6129a05a5 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/configuration/test/BspTestRunConfigurationType.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/configuration/test/BspTestRunConfigurationType.kt @@ -15,7 +15,7 @@ import com.intellij.openapi.project.Project import org.jetbrains.plugins.bsp.assets.BuildToolAssetsExtension import org.jetbrains.plugins.bsp.config.BspPluginBundle import org.jetbrains.plugins.bsp.config.buildToolId -import org.jetbrains.plugins.bsp.flow.open.withBuildToolIdOrDefault +import org.jetbrains.plugins.bsp.extension.points.withBuildToolIdOrDefault import org.jetbrains.plugins.bsp.server.tasks.TestTargetTask import org.jetbrains.plugins.bsp.ui.configuration.BspProcessHandler import org.jetbrains.plugins.bsp.ui.console.BspConsoleService diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/console/BspConsoleService.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/console/BspConsoleService.kt index 4e83ddc2f..834dcd77b 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/console/BspConsoleService.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/console/BspConsoleService.kt @@ -7,7 +7,7 @@ import com.intellij.openapi.project.Project import org.jetbrains.plugins.bsp.assets.BuildToolAssetsExtension import org.jetbrains.plugins.bsp.config.buildToolId import org.jetbrains.plugins.bsp.config.rootDir -import org.jetbrains.plugins.bsp.flow.open.withBuildToolIdOrDefault +import org.jetbrains.plugins.bsp.extension.points.withBuildToolIdOrDefault @Service(Service.Level.PROJECT) public class BspConsoleService(project: Project) { diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/gutters/BspJVMRunLineMarkerContributor.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/gutters/BspJVMRunLineMarkerContributor.kt index 3e8e3c2ae..0c28ceff2 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/gutters/BspJVMRunLineMarkerContributor.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/gutters/BspJVMRunLineMarkerContributor.kt @@ -18,7 +18,7 @@ import org.jetbrains.magicmetamodel.impl.workspacemodel.BuildTargetId import org.jetbrains.plugins.bsp.assets.BuildToolAssetsExtension import org.jetbrains.plugins.bsp.config.buildToolId import org.jetbrains.plugins.bsp.config.isBspProject -import org.jetbrains.plugins.bsp.flow.open.withBuildToolIdOrDefault +import org.jetbrains.plugins.bsp.extension.points.withBuildToolIdOrDefault import org.jetbrains.plugins.bsp.services.MagicMetaModelService import org.jetbrains.plugins.bsp.ui.widgets.tool.window.actions.RunTargetAction import org.jetbrains.plugins.bsp.ui.widgets.tool.window.actions.TestTargetAction diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/project/tree/BspProjectViewNodeDecorator.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/project/tree/BspProjectViewNodeDecorator.kt index d3ed14e86..3c68b9071 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/project/tree/BspProjectViewNodeDecorator.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/project/tree/BspProjectViewNodeDecorator.kt @@ -13,7 +13,7 @@ import com.intellij.workspaceModel.ide.getInstance import org.jetbrains.plugins.bsp.assets.BuildToolAssetsExtension import org.jetbrains.plugins.bsp.config.buildToolId import org.jetbrains.plugins.bsp.config.isBspProject -import org.jetbrains.plugins.bsp.flow.open.withBuildToolIdOrDefault +import org.jetbrains.plugins.bsp.extension.points.withBuildToolIdOrDefault import org.jetbrains.plugins.bsp.services.MagicMetaModelService import javax.swing.Icon diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/document/targets/BspDocumentTargetsWidget.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/document/targets/BspDocumentTargetsWidget.kt index 29aa025f2..df358ac41 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/document/targets/BspDocumentTargetsWidget.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/document/targets/BspDocumentTargetsWidget.kt @@ -20,7 +20,7 @@ import org.jetbrains.plugins.bsp.assets.BuildToolAssetsExtension import org.jetbrains.plugins.bsp.config.BspPluginBundle import org.jetbrains.plugins.bsp.config.buildToolId import org.jetbrains.plugins.bsp.config.isBspProject -import org.jetbrains.plugins.bsp.flow.open.withBuildToolIdOrDefault +import org.jetbrains.plugins.bsp.extension.points.withBuildToolIdOrDefault import org.jetbrains.plugins.bsp.services.MagicMetaModelService import org.jetbrains.plugins.bsp.ui.actions.LoadTargetAction import java.net.URI diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/all/targets/BspAllTargetsWidgetFactory.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/all/targets/BspAllTargetsWidgetFactory.kt index b5fecb3d6..12c05b731 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/all/targets/BspAllTargetsWidgetFactory.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/all/targets/BspAllTargetsWidgetFactory.kt @@ -13,7 +13,7 @@ import kotlinx.coroutines.withContext import org.jetbrains.plugins.bsp.assets.BuildToolAssetsExtension import org.jetbrains.plugins.bsp.config.buildToolId import org.jetbrains.plugins.bsp.config.isBspProject -import org.jetbrains.plugins.bsp.flow.open.withBuildToolIdOrDefault +import org.jetbrains.plugins.bsp.extension.points.withBuildToolIdOrDefault import org.jetbrains.plugins.bsp.ui.widgets.tool.window.components.BspToolWindowPanel import org.jetbrains.plugins.bsp.ui.widgets.tool.window.components.BspToolWindowService diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BspPanelComponent.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BspPanelComponent.kt index c642ef569..89ffb175b 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BspPanelComponent.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BspPanelComponent.kt @@ -7,7 +7,7 @@ import com.intellij.ui.components.panels.VerticalLayout import org.jetbrains.magicmetamodel.impl.workspacemodel.BuildTargetId import org.jetbrains.magicmetamodel.impl.workspacemodel.BuildTargetInfo import org.jetbrains.plugins.bsp.config.BspPluginBundle -import org.jetbrains.plugins.bsp.flow.open.BuildToolId +import org.jetbrains.plugins.bsp.extension.points.BuildToolId import org.jetbrains.plugins.bsp.ui.widgets.tool.window.search.SearchBarPanel import java.awt.Component import java.awt.event.MouseListener diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BspToolWindowPanel.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BspToolWindowPanel.kt index 7a44fdf4c..2e67da622 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BspToolWindowPanel.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BspToolWindowPanel.kt @@ -9,7 +9,7 @@ import org.jetbrains.plugins.bsp.assets.BuildToolAssetsExtension import org.jetbrains.plugins.bsp.config.BspPluginBundle import org.jetbrains.plugins.bsp.config.BspPluginIcons import org.jetbrains.plugins.bsp.config.buildToolId -import org.jetbrains.plugins.bsp.flow.open.withBuildToolIdOrDefault +import org.jetbrains.plugins.bsp.extension.points.withBuildToolIdOrDefault import org.jetbrains.plugins.bsp.services.MagicMetaModelService import org.jetbrains.plugins.bsp.ui.widgets.tool.window.all.targets.StickyTargetAction import org.jetbrains.plugins.bsp.ui.widgets.tool.window.filter.FilterActionGroup diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BuildTargetSearch.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BuildTargetSearch.kt index a64689b1c..26860576f 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BuildTargetSearch.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BuildTargetSearch.kt @@ -7,8 +7,7 @@ import com.intellij.ui.components.panels.VerticalLayout import com.intellij.util.concurrency.NonUrgentExecutor import org.jetbrains.magicmetamodel.impl.workspacemodel.BuildTargetInfo import org.jetbrains.plugins.bsp.config.BspPluginBundle -import org.jetbrains.plugins.bsp.config.buildToolId -import org.jetbrains.plugins.bsp.flow.open.BuildToolId +import org.jetbrains.plugins.bsp.extension.points.BuildToolId import org.jetbrains.plugins.bsp.ui.widgets.tool.window.actions.CopyTargetIdAction import org.jetbrains.plugins.bsp.ui.widgets.tool.window.search.LazySearchListDisplay import org.jetbrains.plugins.bsp.ui.widgets.tool.window.search.LazySearchTreeDisplay diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BuildTargetTree.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BuildTargetTree.kt index f21f0177c..8177b74fa 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BuildTargetTree.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/components/BuildTargetTree.kt @@ -7,7 +7,7 @@ import org.jetbrains.magicmetamodel.impl.workspacemodel.BuildTargetId import org.jetbrains.magicmetamodel.impl.workspacemodel.BuildTargetInfo import org.jetbrains.plugins.bsp.config.BspPluginBundle import org.jetbrains.plugins.bsp.extension.points.BspBuildTargetClassifierExtension -import org.jetbrains.plugins.bsp.flow.open.BuildToolId +import org.jetbrains.plugins.bsp.extension.points.BuildToolId import org.jetbrains.plugins.bsp.ui.widgets.tool.window.actions.CopyTargetIdAction import org.jetbrains.plugins.bsp.ui.widgets.tool.window.utils.BspBuildTargetClassifierProvider import java.awt.Component diff --git a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/search/LazySearchTreeDisplay.kt b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/search/LazySearchTreeDisplay.kt index 6a1bd6cda..9add08f7a 100644 --- a/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/search/LazySearchTreeDisplay.kt +++ b/src/main/kotlin/org/jetbrains/plugins/bsp/ui/widgets/tool/window/search/LazySearchTreeDisplay.kt @@ -1,7 +1,7 @@ package org.jetbrains.plugins.bsp.ui.widgets.tool.window.search import org.jetbrains.magicmetamodel.impl.workspacemodel.BuildTargetInfo -import org.jetbrains.plugins.bsp.flow.open.BuildToolId +import org.jetbrains.plugins.bsp.extension.points.BuildToolId import org.jetbrains.plugins.bsp.ui.widgets.tool.window.components.BuildTargetTree import java.awt.event.MouseListener import javax.swing.Icon diff --git a/src/test/kotlin/org/jetbrains/plugins/bsp/flow/open/GenericBspProjectOpenProcessorTest.kt b/src/test/kotlin/org/jetbrains/plugins/bsp/flow/open/GenericBspProjectOpenProcessorTest.kt index 475184872..b8dd28358 100644 --- a/src/test/kotlin/org/jetbrains/plugins/bsp/flow/open/GenericBspProjectOpenProcessorTest.kt +++ b/src/test/kotlin/org/jetbrains/plugins/bsp/flow/open/GenericBspProjectOpenProcessorTest.kt @@ -8,6 +8,7 @@ import com.intellij.testFramework.registerExtension import com.intellij.testFramework.utils.vfs.createFile import com.intellij.util.application import io.kotest.matchers.shouldBe +import org.jetbrains.plugins.bsp.extension.points.BuildToolId import org.jetbrains.workspace.model.test.framework.MockProjectBaseTest import org.junit.jupiter.api.BeforeEach import org.junit.jupiter.api.DisplayName diff --git a/src/test/kotlin/org/jetbrains/plugins/bsp/runner/BspDebugRunnerTest.kt b/src/test/kotlin/org/jetbrains/plugins/bsp/runner/BspDebugRunnerTest.kt index ca9f1aa9a..7d28fba88 100644 --- a/src/test/kotlin/org/jetbrains/plugins/bsp/runner/BspDebugRunnerTest.kt +++ b/src/test/kotlin/org/jetbrains/plugins/bsp/runner/BspDebugRunnerTest.kt @@ -11,7 +11,7 @@ import com.intellij.openapi.options.SettingsEditor import com.intellij.openapi.project.Project import io.kotest.matchers.shouldBe import org.jetbrains.plugins.bsp.config.buildToolId -import org.jetbrains.plugins.bsp.flow.open.BuildToolId +import org.jetbrains.plugins.bsp.extension.points.BuildToolId import org.jetbrains.plugins.bsp.ui.configuration.run.BspDebugType import org.jetbrains.plugins.bsp.ui.configuration.run.BspRunConfiguration import org.jetbrains.plugins.bsp.ui.configuration.run.BspRunConfigurationType