diff options
Diffstat (limited to 'spec/ruby/core/string/byteindex_spec.rb')
| -rw-r--r-- | spec/ruby/core/string/byteindex_spec.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/ruby/core/string/byteindex_spec.rb b/spec/ruby/core/string/byteindex_spec.rb index d420f3f683..f4c6408790 100644 --- a/spec/ruby/core/string/byteindex_spec.rb +++ b/spec/ruby/core/string/byteindex_spec.rb @@ -149,7 +149,7 @@ describe "String#byteindex with String" do char = "れ".encode Encoding::EUC_JP -> do "あれ".byteindex(char) - end.should raise_error(Encoding::CompatibilityError) + end.should.raise(Encoding::CompatibilityError) end it "handles a substring in a superset encoding" do @@ -255,7 +255,7 @@ describe "String#byteindex with Regexp" do end it "returns nil if the Regexp matches the empty string and the offset is out of range" do - "ruby".byteindex(//, 12).should be_nil + "ruby".byteindex(//, 12).should == nil end it "supports \\G which matches at the given start offset" do |
