1
0
mirror of https://github.com/nvbn/thefuck.git synced 2025-01-31 02:01:13 +00:00

#366 Remove sleep before checking history

This commit is contained in:
nvbn 2015-09-08 17:47:04 +03:00
parent 08af616e3d
commit cb14aded6b

View File

@ -1,6 +1,3 @@
from time import sleep
def _set_confirmation(proc, require):
proc.sendline(u'mkdir -p ~/.thefuck')
proc.sendline(
@ -25,14 +22,12 @@ def with_confirmation(proc, TIMEOUT):
def history_changed(proc, TIMEOUT, to):
"""Ensures that history changed."""
sleep(1)
proc.send('\033[A')
assert proc.expect([TIMEOUT, to])
def history_not_changed(proc, TIMEOUT):
"""Ensures that history not changed."""
sleep(1)
proc.send('\033[A')
assert proc.expect([TIMEOUT, u'fuck'])