1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

[ruby/reline] Add a test for dialog at right edge

db642169b9
This commit is contained in:
aycabta 2021-09-10 06:42:58 +09:00 committed by git
parent c25511ef46
commit c00643c18a

View file

@ -854,6 +854,25 @@ begin
EOC
end
def test_simple_dialog_at_right_edge
start_terminal(20, 40, %W{ruby -I#{@pwd}/lib #{@pwd}/test/reline/yamatanooroti/multiline_repl --dialog simple}, startup_message: 'Multiline REPL.')
write('a')
write('b')
write('c')
write("\C-h")
close
assert_screen(<<~'EOC')
Multiline REPL.
prompt> ab
Ruby is...
A dynamic, open source programming
language with a focus on simplicity
and productivity. It has an elegant
syntax that is natural to read and
easy to write.
EOC
end
def test_simple_dialog_with_scroll_key
start_terminal(20, 50, %W{ruby -I#{@pwd}/lib #{@pwd}/test/reline/yamatanooroti/multiline_repl --dialog long,scrollkey}, startup_message: 'Multiline REPL.')
write('a')