summaryrefslogtreecommitdiff
path: root/test/ruby/test_exception.rb
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2019-10-21 09:27:25 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2019-10-21 09:28:28 +0900
commit27261007eb45adae4d5b30cbafa2ef27a2345b3f (patch)
treea1bd30182ccb2cf3572fb50025c539fbb35f04a6 /test/ruby/test_exception.rb
parent1d29c9bd4601ef2783b5bb7de78ebf43cb282607 (diff)
DidYouMean can be an empty stub module [Bug #16263]
Diffstat (limited to 'test/ruby/test_exception.rb')
-rw-r--r--test/ruby/test_exception.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/ruby/test_exception.rb b/test/ruby/test_exception.rb
index 7ced9a9eba..85ca4dd34a 100644
--- a/test/ruby/test_exception.rb
+++ b/test/ruby/test_exception.rb
@@ -995,7 +995,7 @@ end.join
error = NoMethodError.new("Message", :foo)
assert_raise(ArgumentError) {error.receiver}
- msg = Object.const_defined?(:DidYouMean) ?
+ msg = defined?(:DidYouMean.formatter) ?
"Message\nDid you mean? for" : "Message"
error = NoMethodError.new("Message", :foo, receiver: receiver)