Skip to content

Commit

Permalink
remove ruby 2.2 spec guard
Browse files Browse the repository at this point in the history
  • Loading branch information
tak1n committed May 26, 2015
1 parent ed9fc85 commit dadf147
Showing 1 changed file with 16 additions and 19 deletions.
35 changes: 16 additions & 19 deletions spec/ruby/core/dir/fileno_spec.rb
Expand Up @@ -2,29 +2,26 @@
require File.expand_path('../fixtures/common', __FILE__)

describe "Dir#fileno" do
platform_is_not :windows do
before :each do
@name = tmp("fileno")
mkdir_p @name
end

ruby_version_is "2.2" do
platform_is_not :windows do
before :each do
@name = tmp("fileno")
mkdir_p @name
end

after :each do
rm_r @name
end
after :each do
rm_r @name
end

it "returns the file descriptor of the dir" do
dir = Dir.new(@name)
dir.fileno.should.be_kind_of(Fixnum)
end
it "returns the file descriptor of the dir" do
dir = Dir.new(@name)
dir.fileno.should.be_kind_of(Fixnum)
end
end

platform_is :windows do
it "raises an error" do
dir = Dir.new('.')
lambda { dir.fileno }.to raise_error(NotImplementedError)
end
platform_is :windows do
it "raises an error" do
dir = Dir.new('.')
lambda { dir.fileno }.to raise_error(NotImplementedError)
end
end
end
Expand Down

0 comments on commit dadf147

Please sign in to comment.