diff options
Diffstat (limited to 'spec/ruby/core/string/ord_spec.rb')
| -rw-r--r-- | spec/ruby/core/string/ord_spec.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/ruby/core/string/ord_spec.rb b/spec/ruby/core/string/ord_spec.rb index 35af3b5458..5a17fc1d87 100644 --- a/spec/ruby/core/string/ord_spec.rb +++ b/spec/ruby/core/string/ord_spec.rb @@ -2,7 +2,7 @@ require_relative '../../spec_helper' describe "String#ord" do it "returns an Integer" do - 'a'.ord.should be_an_instance_of(Integer) + 'a'.ord.should.instance_of?(Integer) end it "returns the codepoint of the first character in the String" do @@ -23,11 +23,11 @@ describe "String#ord" do end it "raises an ArgumentError if called on an empty String" do - -> { ''.ord }.should raise_error(ArgumentError) + -> { ''.ord }.should.raise(ArgumentError) end it "raises ArgumentError if the character is broken" do s = "©".dup.force_encoding("US-ASCII") - -> { s.ord }.should raise_error(ArgumentError, "invalid byte sequence in US-ASCII") + -> { s.ord }.should.raise(ArgumentError, "invalid byte sequence in US-ASCII") end end |
