diff options
author | Yusuke Endoh <[email protected]> | 2024-01-19 16:03:38 +0900 |
---|---|---|
committer | Yusuke Endoh <[email protected]> | 2024-02-15 18:42:31 +0900 |
commit | 25d74b9527cd525042ad0b612b794fa331d3a318 (patch) | |
tree | 3b40adf0eb79bb5d7e81640d98dee162c35c076b /test/ruby/test_rubyoptions.rb | |
parent | 926277bf826127c65689ddf01f94e23d538a3b8b (diff) |
Do not include a backtick in error messages and backtraces
[Feature #16495]
Diffstat (limited to 'test/ruby/test_rubyoptions.rb')
-rw-r--r-- | test/ruby/test_rubyoptions.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/test/ruby/test_rubyoptions.rb b/test/ruby/test_rubyoptions.rb index f753ba5574..0406efea79 100644 --- a/test/ruby/test_rubyoptions.rb +++ b/test/ruby/test_rubyoptions.rb @@ -117,7 +117,7 @@ class TestRubyOptions < Test::Unit::TestCase assert_in_out_err(%w(-W:no-experimental -e) + ['p Warning[:experimental]'], "", %w(false), []) assert_in_out_err(%w(-W -e) + ['p Warning[:performance]'], "", %w(false), []) assert_in_out_err(%w(-W:performance -e) + ['p Warning[:performance]'], "", %w(true), []) - assert_in_out_err(%w(-W:qux), "", [], /unknown warning category: `qux'/) + assert_in_out_err(%w(-W:qux), "", [], /unknown warning category: 'qux'/) assert_in_out_err(%w(-w -e) + ['p Warning[:deprecated]'], "", %w(true), []) assert_in_out_err(%w(-W -e) + ['p Warning[:deprecated]'], "", %w(true), []) assert_in_out_err(%w(-We) + ['p Warning[:deprecated]'], "", %w(true), []) @@ -204,7 +204,7 @@ class TestRubyOptions < Test::Unit::TestCase assert_in_out_err(%w(--enable=all --disable=rjit -e) + [""], "", [], []) end assert_in_out_err(%w(--enable foobarbazqux -e) + [""], "", [], - /unknown argument for --enable: `foobarbazqux'/) + /unknown argument for --enable: 'foobarbazqux'/) assert_in_out_err(%w(--enable), "", [], /missing argument for --enable/) end @@ -213,7 +213,7 @@ class TestRubyOptions < Test::Unit::TestCase assert_in_out_err(%w(--disable-all -e) + [""], "", [], []) assert_in_out_err(%w(--disable=all -e) + [""], "", [], []) assert_in_out_err(%w(--disable foobarbazqux -e) + [""], "", [], - /unknown argument for --disable: `foobarbazqux'/) + /unknown argument for --disable: 'foobarbazqux'/) assert_in_out_err(%w(--disable), "", [], /missing argument for --disable/) assert_in_out_err(%w(-e) + ['p defined? Gem'], "", ["nil"], []) assert_in_out_err(%w(--disable-did_you_mean -e) + ['p defined? DidYouMean'], "", ["nil"], []) @@ -443,7 +443,7 @@ class TestRubyOptions < Test::Unit::TestCase ENV['RUBYOPT'] = '-W:no-experimental' assert_in_out_err(%w(), "p Warning[:experimental]", ["false"]) ENV['RUBYOPT'] = '-W:qux' - assert_in_out_err(%w(), "", [], /unknown warning category: `qux'/) + assert_in_out_err(%w(), "", [], /unknown warning category: 'qux'/) ENV['RUBYOPT'] = 'w' assert_in_out_err(%w(), "p $VERBOSE", ["true"]) @@ -558,7 +558,7 @@ class TestRubyOptions < Test::Unit::TestCase t.puts " end" t.puts "end" t.flush - warning = ' warning: found `= literal\' in conditional, should be ==' + warning = ' warning: found \'= literal\' in conditional, should be ==' err = ["#{t.path}:1:#{warning}", "#{t.path}:4:#{warning}", ] @@ -820,8 +820,8 @@ class TestRubyOptions < Test::Unit::TestCase %r( (?: --\sRuby\slevel\sbacktrace\sinformation\s----------------------------------------\n - (?:-e:1:in\s\`(?:block\sin\s)?<main>\'\n)* - -e:1:in\s\`kill\'\n + (?:-e:1:in\s\'(?:block\sin\s)?<main>\'\n)* + -e:1:in\s\'kill\'\n \n )? )x, |