Skip to content

Commit

Permalink
fixed warnings from ruby 2.1.0
Browse files Browse the repository at this point in the history
warning: File.exists? is a deprecated name, use File.exist? instead
  • Loading branch information
walf443 committed Jan 13, 2014
1 parent d4c9fd8 commit cedb4e1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ task :default => [:spec, :cucumber]

task :verify_private_key_present do
private_key = File.expand_path('~/.gem/rspec-gem-private_key.pem')
unless File.exists?(private_key)
unless File.exist?(private_key)
raise "Your private key is not present. This gem should not be built without that."
end
end
Expand Down
2 changes: 1 addition & 1 deletion lib/rspec/core/ruby_project.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def determine_root
end

def find_first_parent_containing(dir)
ascend_until {|path| File.exists?(File.join(path, dir))}
ascend_until {|path| File.exist?(File.join(path, dir))}
end

def ascend_until
Expand Down
2 changes: 1 addition & 1 deletion rspec-core.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Gem::Specification.new do |s|
s.required_ruby_version = '>= 1.8.7'

private_key = File.expand_path('~/.gem/rspec-gem-private_key.pem')
if File.exists?(private_key)
if File.exist?(private_key)
s.signing_key = private_key
s.cert_chain = [File.expand_path('~/.gem/rspec-gem-public_cert.pem')]
end
Expand Down

0 comments on commit cedb4e1

Please sign in to comment.