diff options
Diffstat (limited to 'test/ruby')
| -rw-r--r-- | test/ruby/test_rubyoptions.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/ruby/test_rubyoptions.rb b/test/ruby/test_rubyoptions.rb index d448b08014..c509f22d8d 100644 --- a/test/ruby/test_rubyoptions.rb +++ b/test/ruby/test_rubyoptions.rb @@ -578,4 +578,14 @@ class TestRubyOptions < Test::Unit::TestCase feature2408 = '[ruby-core:26925]' assert_in_out_err(%w[.], "", [], /Is a directory -- \./, feature2408) end + + def test_pflag_gsub + bug7157 = '[ruby-core:47967]' + assert_in_out_err(['-p', '-e', 'gsub(/t.*/){"TEST"}'], %[test], %w[TEST], [], bug7157) + end + + def test_pflag_sub + bug7157 = '[ruby-core:47967]' + assert_in_out_err(['-p', '-e', 'sub(/t.*/){"TEST"}'], %[test], %w[TEST], [], bug7157) + end end |
