diff options
Diffstat (limited to 'spec/ruby/core/io/shared')
-rw-r--r-- | spec/ruby/core/io/shared/binwrite.rb | 8 | ||||
-rw-r--r-- | spec/ruby/core/io/shared/tty.rb | 3 |
2 files changed, 5 insertions, 6 deletions
diff --git a/spec/ruby/core/io/shared/binwrite.rb b/spec/ruby/core/io/shared/binwrite.rb index 29310e1eaf..3649bb47ff 100644 --- a/spec/ruby/core/io/shared/binwrite.rb +++ b/spec/ruby/core/io/shared/binwrite.rb @@ -24,9 +24,9 @@ describe :io_binwrite, shared: true do it "creates a file if missing" do fn = @filename + "xxx" begin - File.exist?(fn).should be_false + File.should_not.exist?(fn) IO.send(@method, fn, "test") - File.exist?(fn).should be_true + File.should.exist?(fn) ensure rm_r fn end @@ -35,9 +35,9 @@ describe :io_binwrite, shared: true do it "creates file if missing even if offset given" do fn = @filename + "xxx" begin - File.exist?(fn).should be_false + File.should_not.exist?(fn) IO.send(@method, fn, "test", 0) - File.exist?(fn).should be_true + File.should.exist?(fn) ensure rm_r fn end diff --git a/spec/ruby/core/io/shared/tty.rb b/spec/ruby/core/io/shared/tty.rb index 82a780a9f3..89ac08ec86 100644 --- a/spec/ruby/core/io/shared/tty.rb +++ b/spec/ruby/core/io/shared/tty.rb @@ -7,8 +7,7 @@ describe :io_tty, shared: true do # check to enabled tty File.open('/dev/tty') {} rescue Errno::ENXIO - # workaround for not configured environment like OS X - 1.should == 1 + skip "workaround for not configured environment like OS X" else File.open('/dev/tty') { |f| f.send(@method) }.should == true end |