diff options
Diffstat (limited to 'spec/ruby/library/logger/device/new_spec.rb')
| -rw-r--r-- | spec/ruby/library/logger/device/new_spec.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/spec/ruby/library/logger/device/new_spec.rb b/spec/ruby/library/logger/device/new_spec.rb index a66c364392..c943e7fbe2 100644 --- a/spec/ruby/library/logger/device/new_spec.rb +++ b/spec/ruby/library/logger/device/new_spec.rb @@ -14,11 +14,11 @@ describe "Logger::LogDevice#new" do it "creates a new log device" do l = Logger::LogDevice.new(@log_file) - l.dev.should be_kind_of(File) + l.dev.should.is_a?(File) end it "receives an IO object to log there as first argument" do - @log_file.should be_kind_of(IO) + @log_file.should.is_a?(IO) l = Logger::LogDevice.new(@log_file) l.write("foo") @log_file.rewind @@ -31,17 +31,17 @@ describe "Logger::LogDevice#new" do l.write("Test message") l.close - File.exist?(path).should be_true + File.should.exist?(path) File.open(path) do |f| - f.readlines.should_not be_empty + f.readlines.should_not.empty? end rm_r path end it "receives options via a hash as second argument" do - lambda { Logger::LogDevice.new(STDERR, - { shift_age: 8, shift_size: 10 - })}.should_not raise_error + -> { + Logger::LogDevice.new(STDERR, shift_age: 8, shift_size: 10) + }.should_not.raise end end |
