summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorJames Wright <jrwrigh.iii@gmail.com>2020-02-27 10:38:32 -0700
committerGitHub <noreply@github.com>2020-02-28 02:38:32 +0900
commit9f0626da643070455fb5d6bb11ff1f483a0c100f (patch)
tree5d34b175ba6f35be663814319a41cf87ba275f01 /test
parentd8cb5c1cf5d11f4fd00bb6cc22f604cd1e38c245 (diff)
Add backward-delete-char/eof action (#1891)
'backward-delete-char/eof' will either abort if query is empty or delete one character backwards.
Diffstat (limited to 'test')
-rwxr-xr-xtest/test_go.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/test_go.rb b/test/test_go.rb
index 4d850d2f..a1fd1357 100755
--- a/test/test_go.rb
+++ b/test/test_go.rb
@@ -1710,6 +1710,20 @@ class TestGoFZF < TestBase
tmux.until { |lines| lines.match_count.zero? }
tmux.until { |lines| !lines[-2].include?('(1)') }
end
+
+ def test_backward_delete_char_eof
+ tmux.send_keys "seq 1000 | #{fzf "--bind 'bs:backward-delete-char/eof'"}", :Enter
+ tmux.until { |lines| lines[-2] == ' 1000/1000' }
+ tmux.send_keys '11'
+ tmux.until { |lines| lines[-1] == '> 11' }
+ tmux.send_keys :BSpace
+ tmux.until { |lines| lines[-1] == '> 1' }
+ tmux.send_keys :BSpace
+ tmux.until { |lines| lines[-1] == '>' }
+ tmux.send_keys :BSpace
+ tmux.prepare
+ end
+
end
module TestShell