diff options
Diffstat (limited to 'spec/ruby/core/io/readchar_spec.rb')
| -rw-r--r-- | spec/ruby/core/io/readchar_spec.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/ruby/core/io/readchar_spec.rb b/spec/ruby/core/io/readchar_spec.rb index a66773851a..29d14880ff 100644 --- a/spec/ruby/core/io/readchar_spec.rb +++ b/spec/ruby/core/io/readchar_spec.rb @@ -7,7 +7,7 @@ describe :io_readchar_internal_encoding, shared: true do end it "sets the String encoding to the internal encoding" do - @io.readchar.encoding.should equal(Encoding::UTF_8) + @io.readchar.encoding.should.equal?(Encoding::UTF_8) end end @@ -31,11 +31,11 @@ describe "IO#readchar" do it "raises an EOFError when invoked at the end of the stream" do @io.read - -> { @io.readchar }.should raise_error(EOFError) + -> { @io.readchar }.should.raise(EOFError) end it "raises IOError on closed stream" do - -> { IOSpecs.closed_io.readchar }.should raise_error(IOError) + -> { IOSpecs.closed_io.readchar }.should.raise(IOError) end end @@ -54,7 +54,7 @@ describe "IO#readchar with internal encoding" do end it "sets the String encoding to the external encoding" do - @io.readchar.encoding.should equal(Encoding::EUC_JP) + @io.readchar.encoding.should.equal?(Encoding::EUC_JP) end end @@ -105,6 +105,6 @@ describe "IO#readchar" do end it "raises EOFError on empty stream" do - -> { @io.readchar }.should raise_error(EOFError) + -> { @io.readchar }.should.raise(EOFError) end end |
