Skip to content

Commit

Permalink
Change .exists? to .exist?
Browse files Browse the repository at this point in the history
  • Loading branch information
MSP-Greg committed Feb 14, 2024
1 parent 0fe8373 commit e7fbc4f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions tests/SketchUp Ruby API/TC_Sketchup_ComponentDefinition.rb
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ def test_save_as
path = "#{temp_dir}/my component.skp"

assert(definition.save_as(path))
assert(File.exists?(path))
assert(File.exist?(path))
assert_equal(definition.path, path)
ensure
File.delete(path)
Expand All @@ -254,7 +254,7 @@ def test_save_as_custom_version
path = "#{temp_dir}/my component.skp"

assert(definition.save_as(path, Sketchup::Model::VERSION_2017))
assert(File.exists?(path))
assert(File.exist?(path))
assert_equal(definition.path, path)
ensure
File.delete(path)
Expand Down Expand Up @@ -299,7 +299,7 @@ def test_save_copy
path = "#{temp_dir}/my component.skp"

assert(definition.save_copy(path))
assert(File.exists?(path))
assert(File.exist?(path))
assert(definition.path != path)
ensure
File.delete(path)
Expand All @@ -321,7 +321,7 @@ def test_save_copy_custom_version
path = "#{temp_dir}/my component.skp"

assert(definition.save_copy(path, Sketchup::Model::VERSION_2017))
assert(File.exists?(path))
assert(File.exist?(path))
assert(definition.path != path)
ensure
File.delete(path)
Expand Down
2 changes: 1 addition & 1 deletion tests/SketchUp Ruby API/utils/image_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module ImageHelper
def create_test_image
entities = Sketchup.active_model.entities
filename = File.join(__dir__, "../shared/99bugs.jpg")
assert(File.exists?(filename), "File missing: #{filename}")
assert(File.exist?(filename), "File missing: #{filename}")
image = Sketchup.active_model.entities.add_image(filename, ORIGIN, 1.m)
image
end
Expand Down

0 comments on commit e7fbc4f

Please sign in to comment.