Make the no-integration test more comprehensive and stronger
This commit is contained in:
parent
85c6d8f16e
commit
4552a474b7
@ -196,8 +196,14 @@ copy --exclude */w.* d1
|
|||||||
# check that turning off shell integration works
|
# check that turning off shell integration works
|
||||||
if ok_login_shell in ('bash', 'zsh'):
|
if ok_login_shell in ('bash', 'zsh'):
|
||||||
for val in ('', 'no-rc', 'enabled no-rc'):
|
for val in ('', 'no-rc', 'enabled no-rc'):
|
||||||
with tempfile.TemporaryDirectory() as tdir:
|
for sh in self.all_possible_sh:
|
||||||
self.check_bootstrap('sh', tdir, ok_login_shell, val)
|
with tempfile.TemporaryDirectory() as tdir:
|
||||||
|
pty = self.check_bootstrap(sh, tdir, ok_login_shell, val)
|
||||||
|
num_lines = len(pty.screen_contents().splitlines())
|
||||||
|
pty.send_cmd_to_child('echo "$TERM=fruity"')
|
||||||
|
pty.wait_till(lambda: 'kitty=fruity' in pty.screen_contents())
|
||||||
|
pty.wait_till(lambda: len(pty.screen_contents().splitlines()) >= num_lines + 2)
|
||||||
|
self.assertEqual(pty.screen.cursor.shape, 0)
|
||||||
|
|
||||||
def check_bootstrap(self, sh, home_dir, login_shell='', SHELL_INTEGRATION_VALUE='enabled', extra_exec='', pre_data='', ssh_opts=None):
|
def check_bootstrap(self, sh, home_dir, login_shell='', SHELL_INTEGRATION_VALUE='enabled', extra_exec='', pre_data='', ssh_opts=None):
|
||||||
ssh_opts = ssh_opts or {}
|
ssh_opts = ssh_opts or {}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user