diff options
Diffstat (limited to 'spec/ruby/core/array/shared/push.rb')
| -rw-r--r-- | spec/ruby/core/array/shared/push.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/ruby/core/array/shared/push.rb b/spec/ruby/core/array/shared/push.rb index df307073cd..ec406e506e 100644 --- a/spec/ruby/core/array/shared/push.rb +++ b/spec/ruby/core/array/shared/push.rb @@ -1,7 +1,7 @@ describe :array_push, shared: true do it "appends the arguments to the array" do a = [ "a", "b", "c" ] - a.send(@method, "d", "e", "f").should equal(a) + a.send(@method, "d", "e", "f").should.equal?(a) a.send(@method).should == ["a", "b", "c", "d", "e", "f"] a.send(@method, 5) a.should == ["a", "b", "c", "d", "e", "f", 5] @@ -26,8 +26,8 @@ describe :array_push, shared: true do array.send(@method, :last).should == [1, 'two', 3.0, array, array, array, array, array, :last] end - it "raises a #{frozen_error_class} on a frozen array" do - -> { ArraySpecs.frozen_array.send(@method, 1) }.should raise_error(frozen_error_class) - -> { ArraySpecs.frozen_array.send(@method) }.should raise_error(frozen_error_class) + it "raises a FrozenError on a frozen array" do + -> { ArraySpecs.frozen_array.send(@method, 1) }.should.raise(FrozenError) + -> { ArraySpecs.frozen_array.send(@method) }.should.raise(FrozenError) end end |
