diff options
Diffstat (limited to 'spec/ruby/core/matchdata/values_at_spec.rb')
| -rw-r--r-- | spec/ruby/core/matchdata/values_at_spec.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/ruby/core/matchdata/values_at_spec.rb b/spec/ruby/core/matchdata/values_at_spec.rb index 535719a2ee..ba5b0e662c 100644 --- a/spec/ruby/core/matchdata/values_at_spec.rb +++ b/spec/ruby/core/matchdata/values_at_spec.rb @@ -26,7 +26,7 @@ describe "MatchData#values_at" do end it "raises RangeError if any element of the range is negative and out of range" do - -> { /(.)(.)(\d+)(\d)/.match("THX1138: The Movie").values_at(-6..3) }.should raise_error(RangeError, "-6..3 out of range") + -> { /(.)(.)(\d+)(\d)/.match("THX1138: The Movie").values_at(-6..3) }.should.raise(RangeError, "-6..3 out of range") end it "supports endless Range" do @@ -71,6 +71,6 @@ describe "MatchData#values_at" do it "fails when passed arguments of unsupported types" do -> { /(.)(.)(\d+)(\d)/.match("THX1138: The Movie").values_at(Object.new) - }.should raise_error(TypeError, "no implicit conversion of Object into Integer") + }.should.raise(TypeError, "no implicit conversion of Object into Integer") end end |
