Skip to content

Commit e9f7298

Browse files
authored
GHI-6911 - Replaced deprecated/removed File.exists? method (#4)
* Fixed the test spec/ey_config_local_spec.rb * Substituted `File.exists?` with `File.exist?` * Added AI comments * Bump up the gem version
1 parent b8ce8a3 commit e9f7298

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

lib/ey_config.rb

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def full_path
2424
end
2525

2626
def init
27-
unless File.exists?(full_path)
27+
unless File.exist?(full_path) # AI-GEN - cursor
2828
err_msg = ""
2929
if detected_a_dev_environment?
3030
ey_config_local_usage
@@ -101,7 +101,7 @@ def find_config(config_paths)
101101
config_paths.each do |config_path|
102102
possible_path = File.expand_path(config_path)
103103
possible_paths << possible_path
104-
if File.exists?(possible_path)
104+
if File.exist?(possible_path) # AI-GEN - cursor
105105
return possible_path
106106
end
107107
end

lib/ey_config/version.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
module EY
22
class Config
3-
VERSION = "0.0.7"
3+
VERSION = "0.0.8" # AI-GEN - cursor
44
end
55
end

spec/ey_config_local_spec.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
end
2222

2323
it 'should create ey_services_config_local.yml' do
24-
File.exist?(EY::Config::Local.config_path).should be_true
24+
expect(File.exist?(EY::Config::Local.config_path)).to be_truthy # AI-GEN - cursor
2525
end
2626

2727
it 'should add the keys passed from the command line' do

0 commit comments

Comments
 (0)