diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/test_windows.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/test_windows.py b/tests/test_windows.py index 8e27d26..f8e4c3d 100644 --- a/tests/test_windows.py +++ b/tests/test_windows.py @@ -44,6 +44,12 @@ class Commands(unittest.TestCase): ["hyprctl", "dispatch", "workspace", "3"]) self.assertEqual(windows.workspace_cmd(3, lua=True)[:2], ["hyprctl", "eval"]) + def test_window_commands_are_dispatched(self): + self.assertEqual(windows.window_cmd("focus", "0x1", lua=True), + ["hyprctl", "eval", 'hl.dispatch(hl.dsp.focus({window = "address:0x1"}))']) + self.assertEqual(windows.window_cmd("close", "0x1", lua=True), + ["hyprctl", "eval", 'hl.dispatch(hl.dsp.window.close({window = "address:0x1"}))']) + def test_address_guard(self): self.assertIsNone(windows.ADDR.fullmatch("0x1;rm")) self.assertTrue(windows.ADDR.fullmatch("0x55897e5c0800")) |
