Make bash integration tests more robust on macOS

This commit is contained in:
Kovid Goyal
2024-01-24 23:07:38 +05:30
parent 1293ee60e0
commit fa11858a72
4 changed files with 10 additions and 4 deletions

View File

@@ -306,7 +306,7 @@ PS1="{ps1}"
self.ae(pty.screen_contents(), f'{ps1}printf "%s^G%s" "a" "b"\nab{ps1}')
self.assertTrue(pty.screen.last_reported_cwd.decode().endswith(self.home_dir))
pty.send_cmd_to_child('echo $HISTFILE')
pty.wait_till(lambda: '.bash_history' in pty.screen_contents())
pty.wait_till(lambda: '.bash_history' in pty.screen_contents().replace('\n', ''))
q = os.path.join(self.home_dir, 'testing-cwd-notification-🐱')
os.mkdir(q)
pty.send_cmd_to_child(f'cd {q}')