From 8453fbf4eb0af2e3265fd34a693b7d0e9167f4d2 Mon Sep 17 00:00:00 2001 From: Mike Will Date: Tue, 15 Jul 2025 16:24:40 -0400 Subject: snap: fix `border_overlap` option for monitor snapping (#10987) --- hyprtester/src/shared.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'hyprtester/src/shared.hpp') diff --git a/hyprtester/src/shared.hpp b/hyprtester/src/shared.hpp index cfce1ba7..8bea4c54 100644 --- a/hyprtester/src/shared.hpp +++ b/hyprtester/src/shared.hpp @@ -44,13 +44,13 @@ namespace Colors { } while (0) #define EXPECT_CONTAINS(haystack, needle) \ - if (!std::string{haystack}.contains(needle)) { \ - NLog::log("{}Failed: {}{} should contain {} but doesn't. Source: {}@{}. Haystack is:\n{}", Colors::RED, Colors::RESET, #haystack, #needle, __FILE__, __LINE__, \ + if (const auto EXPECTED = needle; !std::string{haystack}.contains(EXPECTED)) { \ + NLog::log("{}Failed: {}{} should contain {} but doesn't. Source: {}@{}. Haystack is:\n{}", Colors::RED, Colors::RESET, #haystack, EXPECTED, __FILE__, __LINE__, \ std::string{haystack}); \ ret = 1; \ TESTS_FAILED++; \ } else { \ - NLog::log("{}Passed: {}{} contains {}.", Colors::GREEN, Colors::RESET, #haystack, #needle); \ + NLog::log("{}Passed: {}{} contains {}.", Colors::GREEN, Colors::RESET, #haystack, EXPECTED); \ TESTS_PASSED++; \ } -- cgit v1.2.3