Skip to content

Commit 44cd35e

Browse files
committed
Add a test for narrow screen without scrollbar
1 parent 972cc99 commit 44cd35e

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

test/reline/yamatanooroti/test_rendering.rb

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1073,6 +1073,22 @@ def test_dialog_callback_returns_nil
10731073
end
10741074

10751075
def test_dialog_narrower_than_screen
1076+
start_terminal(20, 11, %W{ruby -I#{@pwd}/lib #{@pwd}/test/reline/yamatanooroti/multiline_repl --dialog simple}, startup_message: 'Multiline REPL.')
1077+
close
1078+
assert_screen(<<~'EOC')
1079+
Multiline R
1080+
EPL.
1081+
prompt>
1082+
Ruby is...
1083+
A dynamic,
1084+
language wi
1085+
and product
1086+
syntax that
1087+
easy to wri
1088+
EOC
1089+
end
1090+
1091+
def test_dialog_narrower_than_screen_with_scrollbar
10761092
start_terminal(20, 11, %W{ruby -I#{@pwd}/lib #{@pwd}/test/reline/yamatanooroti/multiline_repl --autocomplete-long}, startup_message: 'Multiline REPL.')
10771093
write('S' + "\C-i" * 3)
10781094
close

0 commit comments

Comments
 (0)