Skip to content

Commit b5f3efd

Browse files
authored
Fix dynamic_prompt test not executed, remove unnecessary set_input (#585)
1 parent 172453c commit b5f3efd

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

test/irb/test_ruby_lex.rb

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ def calculate_indenting(lines, add_new_line)
4141
ruby_lex = RubyLex.new(context)
4242
mock_io = MockIO_AutoIndent.new(lines, last_line_index, byte_pointer, add_new_line)
4343

44-
ruby_lex.set_input { @io.gets }
4544
ruby_lex.configure_io(mock_io)
4645
mock_io.calculated_indent
4746
end
@@ -653,7 +652,7 @@ def assert_dynamic_prompt(lines, expected_prompt_list)
653652
ruby_lex.set_prompt do |ltype, indent, continue, line_no|
654653
'%03d:%01d:%1s:%s ' % [line_no, indent, ltype, continue ? '*' : '>']
655654
end
656-
ruby_lex.set_input { @io.gets }
655+
ruby_lex.configure_io(io)
657656
end
658657

659658
def test_dyanmic_prompt

0 commit comments

Comments
 (0)