layouts: fix maximize size

This commit is contained in:
Vaxry 2025-12-06 11:32:01 +00:00
parent cedadf4fdc
commit d3c9c54b79
No known key found for this signature in database
GPG key ID: 665806380871D640
3 changed files with 33 additions and 2 deletions

View file

@ -344,6 +344,35 @@ static bool testWindowFocusOnFullscreenConflict() {
return true;
}
static void testMaximizeSize() {
NLog::log("{}Testing maximize size", Colors::GREEN);
EXPECT(spawnKitty("kitty_A"), true);
// check kitty properties. Maximizing shouldnt change its size
{
auto str = getFromSocket("/clients");
EXPECT(str.contains("at: 22,22"), true);
EXPECT(str.contains("size: 1876,1036"), true);
EXPECT(str.contains("fullscreen: 0"), true);
}
OK(getFromSocket("/dispatch fullscreen 1"));
{
auto str = getFromSocket("/clients");
EXPECT(str.contains("at: 22,22"), true);
EXPECT(str.contains("size: 1876,1036"), true);
EXPECT(str.contains("fullscreen: 0"), true);
}
NLog::log("{}Killing all windows", Colors::YELLOW);
Tests::killAllWindows();
NLog::log("{}Expecting 0 windows", Colors::YELLOW);
EXPECT(Tests::windowCount(), 0);
}
static bool test() {
NLog::log("{}Testing windows", Colors::GREEN);
@ -714,6 +743,8 @@ static bool test() {
testGroupRules();
testMaximizeSize();
NLog::log("{}Reloading config", Colors::YELLOW);
OK(getFromSocket("/reload"));