diff options
author | Benoit Daloze <eregontp@gmail.com> | 2020-03-28 00:22:51 +0100 |
---|---|---|
committer | Benoit Daloze <eregontp@gmail.com> | 2020-03-28 00:22:51 +0100 |
commit | f234d51eaba861edea925eabb564a0bee41b96a0 (patch) | |
tree | 3334f36a91fe81ec704f2980ab169231f52c41d0 /spec/ruby/core/comparable | |
parent | 296f68816cf575b3ff920f92aec8a4109a7d81d4 (diff) | |
download | ruby-f234d51eaba861edea925eabb564a0bee41b96a0.tar.gz |
Update to ruby/spec@ec84479
Diffstat (limited to 'spec/ruby/core/comparable')
-rw-r--r-- | spec/ruby/core/comparable/lt_spec.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/ruby/core/comparable/lt_spec.rb b/spec/ruby/core/comparable/lt_spec.rb index 4db92719e2..bca95f8d25 100644 --- a/spec/ruby/core/comparable/lt_spec.rb +++ b/spec/ruby/core/comparable/lt_spec.rb @@ -40,4 +40,10 @@ describe "Comparable#<" do a.should_receive(:<=>).any_number_of_times.and_return(nil) -> { (a < b) }.should raise_error(ArgumentError) end + + it "raises an argument error with a message containing the value" do + -> { ("foo" < 7) }.should raise_error(ArgumentError) { |e| + e.message.should == "comparison of String with 7 failed" + } + end end |