aboutsummaryrefslogtreecommitdiffstats
path: root/test/irb
diff options
context:
space:
mode:
authorTakashi Kokubun <takashikkbn@gmail.com>2019-05-26 11:32:23 -0700
committerTakashi Kokubun <takashikkbn@gmail.com>2019-05-26 11:32:23 -0700
commit64ee8900c89444692c6a51f0153869cb634bb086 (patch)
tree956cc93234f91e4a6068a350259a1a80d9e75bca /test/irb
parent7597f7ecb18ae537002391f9feb7f0e689d3b87b (diff)
downloadruby-64ee8900c89444692c6a51f0153869cb634bb086.tar.gz
Highlight global variable on IRB
Diffstat (limited to 'test/irb')
-rw-r--r--test/irb/test_color.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/irb/test_color.rb b/test/irb/test_color.rb
index 577c737662..4342a7ca6f 100644
--- a/test/irb/test_color.rb
+++ b/test/irb/test_color.rb
@@ -64,6 +64,7 @@ module TestIRB
"`echo`" => "#{RED}`#{CLEAR}#{RED}echo#{CLEAR}#{RED}`#{CLEAR}",
"\t" => "\t", # not ^I
"foo(*%W(bar))" => "foo(*#{RED}%W(#{CLEAR}#{RED}bar#{CLEAR}#{RED})#{CLEAR})",
+ "$stdout" => "#{GREEN}#{BOLD}$stdout#{CLEAR}",
}.each do |code, result|
actual = with_term { IRB::Color.colorize_code(code) }
assert_equal(result, actual, "Case: colorize_code(#{code.dump})\nResult: #{humanized_literal(actual)}")