diff options
| author | Vaxry <43317083+vaxerski@users.noreply.github.com> | 2026-01-15 17:00:47 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-01-15 17:00:47 +0100 |
| commit | ac9df44788492fd1d12da8ec0fbbf691386c45a4 (patch) | |
| tree | 8b655b6e47f26bccc5d4b42e2aa8c53dcc0ce01e /hyprtester/src/tests/main/workspaces.cpp | |
| parent | e0cf88809de12c39ad8a1ad1c0194967b0029ec8 (diff) | |
desktop/workspaceHistory: fix tracking for multiple monitors (#12979)
Diffstat (limited to 'hyprtester/src/tests/main/workspaces.cpp')
| -rw-r--r-- | hyprtester/src/tests/main/workspaces.cpp | 70 |
1 files changed, 67 insertions, 3 deletions
diff --git a/hyprtester/src/tests/main/workspaces.cpp b/hyprtester/src/tests/main/workspaces.cpp index 036ddaf5..a126d1b2 100644 --- a/hyprtester/src/tests/main/workspaces.cpp +++ b/hyprtester/src/tests/main/workspaces.cpp @@ -193,6 +193,68 @@ static bool testAsymmetricGaps() { return true; } +static void testMultimonBAF() { + NLog::log("{}Testing multimon back and forth", Colors::YELLOW); + + OK(getFromSocket("/keyword binds:workspace_back_and_forth 1")); + + OK(getFromSocket("/dispatch focusmonitor HEADLESS-2")); + OK(getFromSocket("/dispatch workspace 1")); + + Tests::spawnKitty(); + + OK(getFromSocket("/dispatch workspace 2")); + + Tests::spawnKitty(); + + OK(getFromSocket("/dispatch focusmonitor HEADLESS-3")); + OK(getFromSocket("/dispatch workspace 3")); + + Tests::spawnKitty(); + + OK(getFromSocket("/dispatch workspace 3")); + + { + auto str = getFromSocket("/activeworkspace"); + EXPECT_CONTAINS(str, "workspace ID 2 "); + } + + OK(getFromSocket("/dispatch workspace 4")); + OK(getFromSocket("/dispatch workspace 4")); + + { + auto str = getFromSocket("/activeworkspace"); + EXPECT_CONTAINS(str, "workspace ID 2 "); + } + + OK(getFromSocket("/dispatch workspace 2")); + + { + auto str = getFromSocket("/activeworkspace"); + EXPECT_CONTAINS(str, "workspace ID 4 "); + } + + OK(getFromSocket("/dispatch workspace 3")); + OK(getFromSocket("/dispatch workspace 3")); + + { + auto str = getFromSocket("/activeworkspace"); + EXPECT_CONTAINS(str, "workspace ID 4 "); + } + + OK(getFromSocket("/dispatch workspace 2")); + OK(getFromSocket("/dispatch workspace 3")); + OK(getFromSocket("/dispatch workspace 1")); + OK(getFromSocket("/dispatch workspace 1")); + + { + auto str = getFromSocket("/activeworkspace"); + EXPECT_CONTAINS(str, "workspace ID 3 "); + } + + Tests::killAllWindows(); +} + static bool test() { NLog::log("{}Testing workspaces", Colors::GREEN); @@ -527,13 +589,15 @@ static bool test() { EXPECT_CONTAINS(str, "class: kitty_B"); } - // destroy the headless output - OK(getFromSocket("/output remove HEADLESS-3")); - // kill all NLog::log("{}Killing all windows", Colors::YELLOW); Tests::killAllWindows(); + testMultimonBAF(); + + // destroy the headless output + OK(getFromSocket("/output remove HEADLESS-3")); + testSpecialWorkspaceFullscreen(); testAsymmetricGaps(); |
