summaryrefslogtreecommitdiff
path: root/spec/ruby/library/set/sortedset/add_spec.rb
diff options
context:
space:
mode:
authorBenoit Daloze <eregontp@gmail.com>2019-07-27 12:40:09 +0200
committerBenoit Daloze <eregontp@gmail.com>2019-07-27 12:40:09 +0200
commit5c276e1cc91c5ab2a41fbf7827af2fed914a2bc0 (patch)
tree05b5c68c8b2a00224d4646ea3b26ce3877efaadd /spec/ruby/library/set/sortedset/add_spec.rb
parenta06301b103371b0b7da8eaca26ba744961769f99 (diff)
Update to ruby/spec@875a09e
Diffstat (limited to 'spec/ruby/library/set/sortedset/add_spec.rb')
-rw-r--r--spec/ruby/library/set/sortedset/add_spec.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/ruby/library/set/sortedset/add_spec.rb b/spec/ruby/library/set/sortedset/add_spec.rb
index 721ac7fac0..5f8bde02f5 100644
--- a/spec/ruby/library/set/sortedset/add_spec.rb
+++ b/spec/ruby/library/set/sortedset/add_spec.rb
@@ -8,13 +8,13 @@ describe "SortedSet#add" do
it "takes only values which responds <=>" do
obj = mock('no_comparison_operator')
obj.stub!(:respond_to?).with(:<=>).and_return(false)
- lambda { SortedSet["hello"].add(obj) }.should raise_error(ArgumentError)
+ -> { SortedSet["hello"].add(obj) }.should raise_error(ArgumentError)
end
it "raises on incompatible <=> comparison" do
# Use #to_a here as elements are sorted only when needed.
# Therefore the <=> incompatibility is only noticed on sorting.
- lambda { SortedSet['1', '2'].add(3).to_a }.should raise_error(ArgumentError)
+ -> { SortedSet['1', '2'].add(3).to_a }.should raise_error(ArgumentError)
end
end