summaryrefslogtreecommitdiff
path: root/hyprtester/src/tests/main/window.cpp
diff options
context:
space:
mode:
authorFlorent Charpentier <114689807+C0Florent@users.noreply.github.com>2026-01-22 02:56:51 +1100
committerGitHub <noreply@github.com>2026-01-21 15:56:51 +0000
commit22fc8136a21676472b232f9462318e16b1d16745 (patch)
treeeedc1bf29e2a4189e1ed202325e51184dee213ef /hyprtester/src/tests/main/window.cpp
parente7985ca4c4fa6ca0d96a2f303c3f0395d2d27b31 (diff)
desktop/windowRule: allow expression in min_size/max_size (#12977)
Diffstat (limited to 'hyprtester/src/tests/main/window.cpp')
-rw-r--r--hyprtester/src/tests/main/window.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/hyprtester/src/tests/main/window.cpp b/hyprtester/src/tests/main/window.cpp
index 524ed893..9adb8120 100644
--- a/hyprtester/src/tests/main/window.cpp
+++ b/hyprtester/src/tests/main/window.cpp
@@ -970,7 +970,8 @@ static bool test() {
Tests::killAllWindows();
// test expression rules
- OK(getFromSocket("/keyword windowrule match:class expr_kitty, float yes, size monitor_w*0.5 monitor_h*0.5, move 20+(monitor_w*0.1) monitor_h*0.5"));
+ OK(getFromSocket("/keyword windowrule match:class expr_kitty, float yes, size monitor_w*0.5 monitor_h*0.5, min_size monitor_w*0.25 monitor_h*0.25, "
+ "max_size monitor_w*0.75 monitor_h*0.75, move 20+(monitor_w*0.1) monitor_h*0.5"));
if (!spawnKitty("expr_kitty"))
return false;
@@ -980,6 +981,14 @@ static bool test() {
EXPECT_CONTAINS(str, "floating: 1");
EXPECT_CONTAINS(str, "at: 212,540");
EXPECT_CONTAINS(str, "size: 960,540");
+
+ auto min = getFromSocket("/getprop active min_size");
+ EXPECT_CONTAINS(min, "480");
+ EXPECT_CONTAINS(min, "270");
+
+ auto max = getFromSocket("/getprop active max_size");
+ EXPECT_CONTAINS(max, "1440");
+ EXPECT_CONTAINS(max, "810");
}
OK(getFromSocket("/reload"));