Class: CleoQualityReview::Runner
- Inherits:
-
Object
- Object
- CleoQualityReview::Runner
- Defined in:
- lib/cleo_quality_review/runner.rb
Overview
Orchestrates a complete quality review run
Defined Under Namespace
Classes: AnalysisContext
Instance Method Summary collapse
-
#initialize(options:, command_runner: CommandRunner.new, clock: Time, check_registry: Checks) ⇒ Runner
constructor
A new instance of Runner.
-
#run ⇒ Run
Execute the quality review.
Constructor Details
#initialize(options:, command_runner: CommandRunner.new, clock: Time, check_registry: Checks) ⇒ Runner
Returns a new instance of Runner.
38 39 40 41 42 43 |
# File 'lib/cleo_quality_review/runner.rb', line 38 def initialize(options:, command_runner: CommandRunner.new, clock: Time, check_registry: Checks) @options = @command_runner = command_runner @clock = clock @check_registry = check_registry end |
Instance Method Details
#run ⇒ Run
Execute the quality review
48 49 50 51 52 53 54 |
# File 'lib/cleo_quality_review/runner.rb', line 48 def run context = analysis_context artifacts = prepare_artifacts(context) return reusable_run(artifacts) if artifacts.complete? execute_fresh_run(context, artifacts) end |