diff --git a/platform/testFramework/junit5/eel/test/params/api/EelHolder.kt b/platform/testFramework/junit5/eel/test/params/api/EelHolder.kt index a6fdb2956854..fc96eab6fce6 100644 --- a/platform/testFramework/junit5/eel/test/params/api/EelHolder.kt +++ b/platform/testFramework/junit5/eel/test/params/api/EelHolder.kt @@ -21,4 +21,9 @@ sealed interface EelHolder { * Consider using [eel] in a new code. */ val target: TargetEnvironmentConfiguration? + + /** + * For those rare cases when you need to test something WSL or Docker-specific. Do not use unless absolutely necessary. + */ + val type: EelType } \ No newline at end of file diff --git a/platform/testFramework/junit5/eel/test/params/api/EelType.kt b/platform/testFramework/junit5/eel/test/params/api/EelType.kt new file mode 100644 index 000000000000..cf6af4f5508b --- /dev/null +++ b/platform/testFramework/junit5/eel/test/params/api/EelType.kt @@ -0,0 +1,7 @@ +// Copyright 2000-2025 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. +package com.intellij.platform.testFramework.junit5.eel.params.api + +import org.jetbrains.annotations.ApiStatus + +@ApiStatus.Internal +enum class EelType {LOCAL, WSL, DOCKER} \ No newline at end of file diff --git a/platform/testFramework/junit5/eel/test/params/api/impl.kt b/platform/testFramework/junit5/eel/test/params/api/impl.kt index 50a61eb4a131..e92c33150e03 100644 --- a/platform/testFramework/junit5/eel/test/params/api/impl.kt +++ b/platform/testFramework/junit5/eel/test/params/api/impl.kt @@ -13,6 +13,7 @@ import org.jetbrains.annotations.TestOnly internal class EelHolderImpl(val eelTestProvider: EelIjentTestProvider, val annotation: T?) : EelHolder { override lateinit var eel: IjentApi override var target: TargetEnvironmentConfiguration? = null + override val type: EelType = eelTestProvider.eelType override fun toString(): String = buildString { append(eelTestProvider.name) @@ -26,6 +27,7 @@ internal class EelHolderImpl(val eelTestProvider: EelIjentTestPr @TestOnly internal object LocalEelHolder : EelHolder { + override val type: EelType = EelType.LOCAL override val eel: EelApi get() = localEel override fun toString(): String = "Local" override val target: TargetEnvironmentConfiguration? = null diff --git a/platform/testFramework/junit5/eel/test/params/spi/EelIjentTestProvider.kt b/platform/testFramework/junit5/eel/test/params/spi/EelIjentTestProvider.kt index 61fb3b1c0cb0..4d88d4adeb7b 100644 --- a/platform/testFramework/junit5/eel/test/params/spi/EelIjentTestProvider.kt +++ b/platform/testFramework/junit5/eel/test/params/spi/EelIjentTestProvider.kt @@ -3,6 +3,7 @@ package com.intellij.platform.testFramework.junit5.eel.params.spi import com.intellij.execution.target.TargetEnvironmentConfiguration import com.intellij.platform.ijent.IjentApi +import com.intellij.platform.testFramework.junit5.eel.params.api.EelType import kotlinx.coroutines.CoroutineScope import org.jetbrains.annotations.TestOnly import java.io.Closeable @@ -14,6 +15,7 @@ import kotlin.reflect.KClass */ @TestOnly interface EelIjentTestProvider { + val eelType: EelType val name: String val mandatoryAnnotationClass: KClass