diff options
author | Benoit Daloze <eregontp@gmail.com> | 2020-05-03 12:28:29 +0200 |
---|---|---|
committer | Benoit Daloze <eregontp@gmail.com> | 2020-05-03 12:28:29 +0200 |
commit | 5aaa75e7c1f4b7912c10ffdcb1cac581e20eda39 (patch) | |
tree | e1694f5a4a5558884b1b8f3890b186793e5e982f /spec/ruby/core/io/shared | |
parent | f646d20aaeb8f02bcd3d0c5c3f5a372da654502a (diff) |
Update to ruby/spec@032ee74
Diffstat (limited to 'spec/ruby/core/io/shared')
-rw-r--r-- | spec/ruby/core/io/shared/new.rb | 12 | ||||
-rw-r--r-- | spec/ruby/core/io/shared/pos.rb | 2 |
2 files changed, 7 insertions, 7 deletions
diff --git a/spec/ruby/core/io/shared/new.rb b/spec/ruby/core/io/shared/new.rb index 27d32f97ed..87f3001862 100644 --- a/spec/ruby/core/io/shared/new.rb +++ b/spec/ruby/core/io/shared/new.rb @@ -148,22 +148,22 @@ describe :io_new, shared: true do it "sets binmode from mode string" do @io = IO.send(@method, @fd, 'wb') - @io.binmode?.should == true + @io.should.binmode? end it "does not set binmode without being asked" do @io = IO.send(@method, @fd, 'w') - @io.binmode?.should == false + @io.should_not.binmode? end it "sets binmode from :binmode option" do @io = IO.send(@method, @fd, 'w', binmode: true) - @io.binmode?.should == true + @io.should.binmode? end it "does not set binmode from false :binmode" do @io = IO.send(@method, @fd, 'w', binmode: false) - @io.binmode?.should == false + @io.should_not.binmode? end it "sets external encoding to binary with binmode in mode string" do @@ -270,13 +270,13 @@ describe :io_new, shared: true do it "accepts an :autoclose option" do @io = IO.send(@method, @fd, 'w', autoclose: false) - @io.autoclose?.should == false + @io.should_not.autoclose? @io.autoclose = true end it "accepts any truthy option :autoclose" do @io = IO.send(@method, @fd, 'w', autoclose: 42) - @io.autoclose?.should == true + @io.should.autoclose? end end diff --git a/spec/ruby/core/io/shared/pos.rb b/spec/ruby/core/io/shared/pos.rb index fb6d8087bc..0b4d1e13b3 100644 --- a/spec/ruby/core/io/shared/pos.rb +++ b/spec/ruby/core/io/shared/pos.rb @@ -27,7 +27,7 @@ describe :io_pos, shared: true do io.read 1 io.read 1 io.send(@method) - io.eof?.should == false + io.should_not.eof? end end end |