From 86e3994e87b264f874ea1620fc31f42e3744aad0 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Fri, 6 Dec 2019 22:34:45 +0900 Subject: Properly clear list when --header-lines not filled on reload --- test/test_go.rb | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'test') diff --git a/test/test_go.rb b/test/test_go.rb index 8d6fb37c..55c8fc2b 100755 --- a/test/test_go.rb +++ b/test/test_go.rb @@ -1647,6 +1647,13 @@ class TestGoFZF < TestBase tmux.send_keys :Space tmux.until { |lines| lines.item_count == 10 } end + + def test_clear_list_when_header_lines_changed_due_to_reload + tmux.send_keys %(seq 10 | #{FZF} --header 0 --header-lines 3 --bind 'space:reload(seq 1)'), :Enter + tmux.until { |lines| lines.any? { |line| line.include?('9') } } + tmux.send_keys :Space + tmux.until { |lines| lines.none? { |line| line.include?('9') } } + end end module TestShell -- cgit v1.2.3