Class: BundleSafeUpdate::OutdatedChecker
- Inherits:
-
Object
- Object
- BundleSafeUpdate::OutdatedChecker
- Defined in:
- lib/bundle_safe_update/outdated_checker.rb
Defined Under Namespace
Classes: OutdatedGem
Constant Summary collapse
- BUNDLE_COMMAND =
%w[bundle outdated --parseable].freeze
Instance Method Summary collapse
-
#initialize(gems: [], executor: nil) ⇒ OutdatedChecker
constructor
A new instance of OutdatedChecker.
- #outdated_gems ⇒ Object
Constructor Details
#initialize(gems: [], executor: nil) ⇒ OutdatedChecker
Returns a new instance of OutdatedChecker.
12 13 14 15 |
# File 'lib/bundle_safe_update/outdated_checker.rb', line 12 def initialize(gems: [], executor: nil) @gems = gems @executor = executor || method(:execute_command) end |
Instance Method Details
#outdated_gems ⇒ Object
17 18 19 20 21 |
# File 'lib/bundle_safe_update/outdated_checker.rb', line 17 def outdated_gems command = BUNDLE_COMMAND + @gems output = @executor.call(command) parse_output(output) end |