From f076a315bb7b005528c3fbfa69ed2443ea4275cf Mon Sep 17 00:00:00 2001 From: Konstantin Hudyakov Date: Mon, 6 Jul 2026 15:35:59 +0300 Subject: [PATCH] [terminal] IJPL-248564 Refactor TerminalCopyOnSelectionTest: use 'before' function instead of 'setUp' (cherry picked from commit 8f4ea784d1417c83b1e5042afefdf2446f8434ec) IJ-CR-211956 GitOrigin-RevId: 3a335912459c71c63fe92c49eb2141aec0612d3c --- .../tests/reworked/frontend/TerminalCopyOnSelectionTest.kt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/terminal/tests/src/com/intellij/terminal/tests/reworked/frontend/TerminalCopyOnSelectionTest.kt b/plugins/terminal/tests/src/com/intellij/terminal/tests/reworked/frontend/TerminalCopyOnSelectionTest.kt index e3dcb21d7703..0ef117e0378e 100644 --- a/plugins/terminal/tests/src/com/intellij/terminal/tests/reworked/frontend/TerminalCopyOnSelectionTest.kt +++ b/plugins/terminal/tests/src/com/intellij/terminal/tests/reworked/frontend/TerminalCopyOnSelectionTest.kt @@ -13,6 +13,7 @@ import com.intellij.testFramework.fixtures.BasePlatformTestCase import kotlinx.coroutines.cancel import org.jetbrains.plugins.terminal.util.terminalProjectScope import org.junit.Assume +import org.junit.Before import org.junit.Test import org.junit.jupiter.api.condition.OS import org.junit.runner.RunWith @@ -21,8 +22,8 @@ import java.awt.datatransfer.DataFlavor @RunWith(JUnit4::class) internal class TerminalCopyOnSelectionTest : BasePlatformTestCase() { - override fun setUp() { - super.setUp() + @Before + fun requireNotLinux() { Assume.assumeTrue("Can't run this test on Linux because non-headless mode is required to access system selection content", OS.current() != OS.LINUX) }