summaryrefslogtreecommitdiff
path: root/spec/ruby/library/stringio/shared/each.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/ruby/library/stringio/shared/each.rb')
-rw-r--r--spec/ruby/library/stringio/shared/each.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/ruby/library/stringio/shared/each.rb b/spec/ruby/library/stringio/shared/each.rb
index 55ed27c1c7..c08d40344c 100644
--- a/spec/ruby/library/stringio/shared/each.rb
+++ b/spec/ruby/library/stringio/shared/each.rb
@@ -96,11 +96,11 @@ end
describe :stringio_each_not_readable, shared: true do
it "raises an IOError" do
io = StringIO.new("a b c d e", "w")
- lambda { io.send(@method) { |b| b } }.should raise_error(IOError)
+ -> { io.send(@method) { |b| b } }.should raise_error(IOError)
io = StringIO.new("a b c d e")
io.close_read
- lambda { io.send(@method) { |b| b } }.should raise_error(IOError)
+ -> { io.send(@method) { |b| b } }.should raise_error(IOError)
end
end