mirror of
https://github.com/kovidgoyal/kitty.git
synced 2024-09-21 11:39:57 +03:00
Separate test for SIGWINCH handling
This commit is contained in:
parent
df8800b7ff
commit
78542ede14
@ -92,12 +92,18 @@ def wait_for_death(exit_code, timeout=5):
|
|||||||
# pty = self.create_pty(
|
# pty = self.create_pty(
|
||||||
# argv=[kitty_exe(), '+runpy', src + 'socket_child_main(initial_print="child ready:")'], cols=cols, env=env, cwd=cwd)
|
# argv=[kitty_exe(), '+runpy', src + 'socket_child_main(initial_print="child ready:")'], cols=cols, env=env, cwd=cwd)
|
||||||
# pty.wait_till(lambda: 'child ready:' in pty.screen_contents())
|
# pty.wait_till(lambda: 'child ready:' in pty.screen_contents())
|
||||||
# pty.set_window_size(columns=cols + 3)
|
|
||||||
# pty.wait_till(lambda: f'Screen size changed: {cols + 3}' in pty.screen_contents())
|
|
||||||
# pty.write_to_child('\x03', flush=True)
|
# pty.write_to_child('\x03', flush=True)
|
||||||
# wait_for_death(signal.SIGINT, timeout=30)
|
# wait_for_death(signal.SIGINT, timeout=30)
|
||||||
# pty.wait_till(lambda: 'KeyboardInterrupt' in pty.screen_contents())
|
# pty.wait_till(lambda: 'KeyboardInterrupt' in pty.screen_contents())
|
||||||
|
|
||||||
|
# test SIGWINCH handling
|
||||||
|
pty = self.create_pty(
|
||||||
|
argv=[kitty_exe(), '+runpy', src + 'socket_child_main(initial_print="child ready:")'], cols=cols, env=env, cwd=cwd)
|
||||||
|
pty.wait_till(lambda: 'child ready:' in pty.screen_contents())
|
||||||
|
pty.set_window_size(columns=cols + 3)
|
||||||
|
pty.wait_till(lambda: f'Screen size changed: {cols + 3}' in pty.screen_contents())
|
||||||
|
os.close(pty.master_fd)
|
||||||
|
|
||||||
# test passing of data via cwd, env vars and stdin/stdout redirection
|
# test passing of data via cwd, env vars and stdin/stdout redirection
|
||||||
stdin_r, stdin_w = os.pipe()
|
stdin_r, stdin_w = os.pipe()
|
||||||
os.set_inheritable(stdin_w, False)
|
os.set_inheritable(stdin_w, False)
|
||||||
|
Loading…
Reference in New Issue
Block a user