summaryrefslogtreecommitdiff
path: root/test/irb/test_ruby_lex.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/irb/test_ruby_lex.rb')
-rw-r--r--test/irb/test_ruby_lex.rb10
1 files changed, 8 insertions, 2 deletions
diff --git a/test/irb/test_ruby_lex.rb b/test/irb/test_ruby_lex.rb
index 255a5a1a63..41b5d49d1e 100644
--- a/test/irb/test_ruby_lex.rb
+++ b/test/irb/test_ruby_lex.rb
@@ -281,8 +281,14 @@ module TestIRB
skip if RUBY_ENGINE == 'truffleruby'
ruby_lex = RubyLex.new()
io = MockIO_DynamicPrompt.new(lines) do |prompt_list|
- error_message = "Calculated the wrong number of spaces for:\n #{lines.join("\n")}"
- assert_equal(expected_prompt_list, prompt_list)
+ error_message = <<~EOM
+ Expected dynamic prompt:
+ #{expected_prompt_list.join("\n")}
+
+ Actual dynamic prompt:
+ #{prompt_list.join("\n")}
+ EOM
+ assert_equal(expected_prompt_list, prompt_list, error_message)
end
ruby_lex.set_prompt do |ltype, indent, continue, line_no|
'%03d:%01d:%1s:%s ' % [line_no, indent, ltype, continue ? '*' : '>']