Skip to content

Commit

Permalink
Guard Geom 2d objects (SU 2018?)
Browse files Browse the repository at this point in the history
  • Loading branch information
MSP-Greg committed Jan 3, 2024
1 parent 5645955 commit 0da2f47
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
3 changes: 3 additions & 0 deletions tests/SketchUp Ruby API/TC_Geom_Point2d.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# License:: The MIT License (MIT)
# Original Author:: Adam Karkkainen

if Geom.const_defined? :Point2d

require "testup/testcase"
require_relative "utils/frozen"
Expand Down Expand Up @@ -653,3 +654,5 @@ def test_y_Set_invalid_values
end
end
end # class

end # if Geom.const_defined? :Point2d
5 changes: 4 additions & 1 deletion tests/SketchUp Ruby API/TC_Geom_Transformation2d.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# License:: The MIT License (MIT)
# Original Author:: Adam Karkkainen

if Geom.const_defined? :Transformation2d

require "testup/testcase"
require_relative "utils/frozen"
Expand Down Expand Up @@ -484,4 +485,6 @@ def test_translation_invalid_arguments
Geom::Transformation2d.translation(matrix)
end
end
end
end

end # if Geom.const_defined? :Transformation2d
3 changes: 3 additions & 0 deletions tests/SketchUp Ruby API/TC_Geom_Vector2d.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# License:: The MIT License (MIT)
# Original Author:: Adam Karkkainen

if Geom.const_defined? :Vector2d

require "testup/testcase"
require_relative "utils/frozen"
Expand Down Expand Up @@ -1170,3 +1171,5 @@ def test_y_Set_invalid_types
end
end
end

end # if Geom.const_defined? :Vector2d

0 comments on commit 0da2f47

Please sign in to comment.