diff options
Diffstat (limited to 'spec/ruby/core/array/shared/replace.rb')
| -rw-r--r-- | spec/ruby/core/array/shared/replace.rb | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/spec/ruby/core/array/shared/replace.rb b/spec/ruby/core/array/shared/replace.rb index b8dae8d33e..06bfd00795 100644 --- a/spec/ruby/core/array/shared/replace.rb +++ b/spec/ruby/core/array/shared/replace.rb @@ -2,9 +2,9 @@ describe :array_replace, shared: true do it "replaces the elements with elements from other array" do a = [1, 2, 3, 4, 5] b = ['a', 'b', 'c'] - a.send(@method, b).should equal(a) + a.send(@method, b).should.equal?(a) a.should == b - a.should_not equal(b) + a.should_not.equal?(b) a.send(@method, [4] * 10) a.should == [4] * 10 @@ -27,7 +27,7 @@ describe :array_replace, shared: true do it "returns self" do ary = [1, 2, 3] other = [:a, :b, :c] - ary.send(@method, other).should equal(ary) + ary.send(@method, other).should.equal?(ary) end it "does not make self dependent to the original array" do @@ -52,9 +52,9 @@ describe :array_replace, shared: true do [].send(@method, ArraySpecs::ToAryArray[5, 6, 7]).should == [5, 6, 7] end - it "raises a #{frozen_error_class} on a frozen array" do - lambda { + it "raises a FrozenError on a frozen array" do + -> { ArraySpecs.frozen_array.send(@method, ArraySpecs.frozen_array) - }.should raise_error(frozen_error_class) + }.should.raise(FrozenError) end end |
