diff options
author | Yusuke Endoh <mame@ruby-lang.org> | 2021-06-18 17:11:39 +0900 |
---|---|---|
committer | Yusuke Endoh <mame@ruby-lang.org> | 2021-06-29 23:45:49 +0900 |
commit | e94604966572bb43fc887856d54aa54b8e9f7719 (patch) | |
tree | 789d92c232f671c6620af5c4bfd1a3fc0d9d26b3 /spec/ruby | |
parent | 03dc66449326ce0945c1ccad7f51e57125b2b854 (diff) |
[WIP] add error_squiggle gem
```
$ ./local/bin/ruby -e '1.time {}'
-e:1:in `<main>': undefined method `time' for 1:Integer (NoMethodError)
1.time {}
^^^^^
Did you mean? times
```
https://bugs.ruby-lang.org/issues/17930
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/4586
Diffstat (limited to 'spec/ruby')
-rw-r--r-- | spec/ruby/core/exception/no_method_error_spec.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/ruby/core/exception/no_method_error_spec.rb b/spec/ruby/core/exception/no_method_error_spec.rb index 570ffc47b1..a93ef2187e 100644 --- a/spec/ruby/core/exception/no_method_error_spec.rb +++ b/spec/ruby/core/exception/no_method_error_spec.rb @@ -110,14 +110,14 @@ describe "NoMethodError#message" do begin klass.foo rescue NoMethodError => error - error.message.lines.first.should == "undefined method `foo' for MyClass:Class" + error.message.lines.first.chomp.should == "undefined method `foo' for MyClass:Class" end mod = Module.new { def self.name; "MyModule"; end } begin mod.foo rescue NoMethodError => error - error.message.lines.first.should == "undefined method `foo' for MyModule:Module" + error.message.lines.first.chomp.should == "undefined method `foo' for MyModule:Module" end end end |