Class: SleepingKingStudios::Tasks::ProcessRunner
- Inherits:
-
Object
- Object
- SleepingKingStudios::Tasks::ProcessRunner
- Defined in:
- lib/sleeping_king_studios/tasks/process_runner.rb
Overview
Base class for helpers that execute a system process.
Direct Known Subclasses
Apps::Bundle::InstallRunner, Apps::Bundle::UpdateRunner, Ci::CucumberRunner, Ci::RSpecRunner, Ci::RuboCopRunner
Instance Attribute Summary collapse
-
#default_env ⇒ Hash
readonly
Environment variables to set for the RSpec process.
-
#default_options ⇒ Array
readonly
Options to pass to RSpec.
Instance Method Summary collapse
-
#initialize(env: {}, options: []) ⇒ ProcessRunner
constructor
A new instance of ProcessRunner.
Constructor Details
#initialize(env: {}, options: []) ⇒ ProcessRunner
Returns a new instance of ProcessRunner.
10 11 12 13 14 15 16 17 |
# File 'lib/sleeping_king_studios/tasks/process_runner.rb', line 10 def initialize env: {}, options: [] @default_env = env.dup @default_options = return unless ENV['BUNDLE_GEMFILE'] @default_env[:bundle_gemfile] ||= ENV['BUNDLE_GEMFILE'] end |
Instance Attribute Details
#default_env ⇒ Hash (readonly)
Returns Environment variables to set for the RSpec process.
20 21 22 |
# File 'lib/sleeping_king_studios/tasks/process_runner.rb', line 20 def default_env @default_env end |
#default_options ⇒ Array (readonly)
Returns Options to pass to RSpec.
23 24 25 |
# File 'lib/sleeping_king_studios/tasks/process_runner.rb', line 23 def @default_options end |