aboutsummaryrefslogtreecommitdiffstats
path: root/spec/ruby/core/string/prepend_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/ruby/core/string/prepend_spec.rb')
-rw-r--r--spec/ruby/core/string/prepend_spec.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/ruby/core/string/prepend_spec.rb b/spec/ruby/core/string/prepend_spec.rb
index e2c29de836..485c578e2d 100644
--- a/spec/ruby/core/string/prepend_spec.rb
+++ b/spec/ruby/core/string/prepend_spec.rb
@@ -16,16 +16,16 @@ describe "String#prepend" do
end
it "raises a TypeError if the given argument can't be converted to a String" do
- lambda { "hello ".prepend [] }.should raise_error(TypeError)
- lambda { 'hello '.prepend mock('x') }.should raise_error(TypeError)
+ -> { "hello ".prepend [] }.should raise_error(TypeError)
+ -> { 'hello '.prepend mock('x') }.should raise_error(TypeError)
end
it "raises a #{frozen_error_class} when self is frozen" do
a = "hello"
a.freeze
- lambda { a.prepend "" }.should raise_error(frozen_error_class)
- lambda { a.prepend "test" }.should raise_error(frozen_error_class)
+ -> { a.prepend "" }.should raise_error(frozen_error_class)
+ -> { a.prepend "test" }.should raise_error(frozen_error_class)
end
it "works when given a subclass instance" do