-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update to use Minitest 5.15.0 #217
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,7 +14,7 @@ module GemHelper | |
def self.require(gem_name, filename, version: Gem::Requirement.default) | ||
Kernel.require 'rubygems' | ||
begin | ||
gem gem_name | ||
gem gem_name, ">=#{version}" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah, nice. didn't realize you could use a flexible version here. |
||
rescue Gem::LoadError | ||
puts "Installing Gem: #{gem_name} (Please wait...)" | ||
begin | ||
|
@@ -24,7 +24,7 @@ def self.require(gem_name, filename, version: Gem::Requirement.default) | |
# a bug. This pattern is probably not that common, to be | ||
# programmatically installing gems. | ||
end | ||
gem gem_name | ||
gem gem_name, ">=#{version}" | ||
end | ||
Kernel.require filename | ||
end | ||
|
@@ -58,7 +58,8 @@ def self.install(gem_name, version = Gem::Requirement.default) | |
if local_path | ||
puts '> Installing from local copy...' | ||
puts "> #{local_path}" | ||
Gem.install(local_path) | ||
Gem.install(local_path, nil, {domain: :local}) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ruby 2.2, SU 2017. It doesn't exist in Ruby 2.0, not sure about 2.1 |
||
puts "> Installed #{gem_name}-#{version}" | ||
else | ||
puts '> Installing from Ruby Gems...' | ||
Gem.install(gem_name, version) | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,7 @@ | |
# License:: The MIT License (MIT) | ||
# Original Author:: Adam Karkkainen | ||
|
||
if Geom.const_defined? :Point2d | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What are these conditionals for? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh, for running on older SketchUp versions? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Yes. I wanted to see if it worked with Ruby 2.2, so I tried SU 2017. The '2d' objects were new with SU 2018, JFYI, doc's refer to Layout (not SU) in their minimum version item. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yea, the 2d classes was introduced because of LayOut. SketchUp never really used them. I think we might have introduced some usage of them later on though. |
||
|
||
require "testup/testcase" | ||
require_relative "utils/frozen" | ||
|
@@ -653,3 +654,5 @@ def test_y_Set_invalid_values | |
end | ||
end | ||
end # class | ||
|
||
end # if Geom.const_defined? :Point2d |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With that the
.rubocop.yml
should updateTargetSketchUpVersion
andTargetRubyVersion
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wasn't sure what you wanted to do, I don't think I have a complete set of old Ruby 2.2. SU versions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can have a look at the rubocop config.