From eb91715f10515b8cddc46ffa13ae1fbf820e241b Mon Sep 17 00:00:00 2001 From: Luke Hill Date: Mon, 1 Jul 2019 13:02:32 +0200 Subject: [PATCH 1/8] AutoFix some positional cops --- features/step_definitions/hooks.rb | 20 ++++----- lib/aruba/initializer.rb | 56 +++++++++++++------------- spec/aruba/matchers/collection_spec.rb | 12 +++--- 3 files changed, 44 insertions(+), 44 deletions(-) diff --git a/features/step_definitions/hooks.rb b/features/step_definitions/hooks.rb index 5db0297aa..69e00b26f 100644 --- a/features/step_definitions/hooks.rb +++ b/features/step_definitions/hooks.rb @@ -1,6 +1,6 @@ require 'cucumber/platform' -Before '@requires-python' do |scenario| +Before '@requires-python' do |_scenario| next unless Aruba.platform.which('python').nil? skip_this_scenario @@ -16,45 +16,45 @@ end end -Before '@requires-java' do |scenario| +Before '@requires-java' do |_scenario| next unless Aruba.platform.which('javac').nil? skip_this_scenario end -Before '@requires-perl' do |scenario| +Before '@requires-perl' do |_scenario| next unless Aruba.platform.which('perl').nil? skip_this_scenario end -Before '@requires-ruby' do |scenario| +Before '@requires-ruby' do |_scenario| next unless Aruba.platform.which('ruby').nil? skip_this_scenario end -Before '@requires-posix-standard-tools' do |scenario| +Before '@requires-posix-standard-tools' do |_scenario| next unless Aruba.platform.which('printf').nil? skip_this_scenario end -Before '@requires-ruby-platform-java' do |scenario| +Before '@requires-ruby-platform-java' do |_scenario| # leave if java next if RUBY_PLATFORM.include? 'java' skip_this_scenario end -Before '@unsupported-on-platform-java' do |scenario| +Before '@unsupported-on-platform-java' do |_scenario| # leave if not java next unless RUBY_PLATFORM.include? 'java' skip_this_scenario end -Before '@unsupported-on-platform-windows' do |scenario| +Before '@unsupported-on-platform-windows' do |_scenario| # leave if not windows next unless FFI::Platform.windows? @@ -69,14 +69,14 @@ end end -Before '@unsupported-on-platform-unix' do |scenario| +Before '@unsupported-on-platform-unix' do |_scenario| # leave if not windows next unless FFI::Platform.unix? skip_this_scenario end -Before '@unsupported-on-platform-mac' do |scenario| +Before '@unsupported-on-platform-mac' do |_scenario| # leave if not windows next unless FFI::Platform.mac? diff --git a/lib/aruba/initializer.rb b/lib/aruba/initializer.rb index 28b3ed706..fdb756766 100644 --- a/lib/aruba/initializer.rb +++ b/lib/aruba/initializer.rb @@ -80,18 +80,18 @@ def create_helper :create_file end - send creator, file, <<-EOS -$LOAD_PATH.unshift File.expand_path('../../lib', __FILE__) + send creator, file, <<~EOS + $LOAD_PATH.unshift File.expand_path('../../lib', __FILE__) -::Dir.glob(::File.expand_path('../support/*.rb', __FILE__)).each { |f| require_relative f } -::Dir.glob(::File.expand_path('../support/**/*.rb', __FILE__)).each { |f| require_relative f } -EOS + ::Dir.glob(::File.expand_path('../support/*.rb', __FILE__)).each { |f| require_relative f } + ::Dir.glob(::File.expand_path('../support/**/*.rb', __FILE__)).each { |f| require_relative f } + EOS end def create_support_file - create_file 'spec/support/aruba.rb', <<-EOS -require 'aruba/rspec' -EOS + create_file 'spec/support/aruba.rb', <<~EOS + require 'aruba/rspec' + EOS end end end @@ -114,9 +114,9 @@ def self.match?(framework) end def create_support_file - create_file 'features/support/aruba.rb', <<-EOS -require 'aruba/cucumber' -EOS + create_file 'features/support/aruba.rb', <<~EOS + require 'aruba/cucumber' + EOS end end end @@ -146,30 +146,30 @@ def create_helper :create_file end - send creator, file, <<-EOS -$LOAD_PATH.unshift File.expand_path('../../lib', __FILE__) + send creator, file, <<~EOS + $LOAD_PATH.unshift File.expand_path('../../lib', __FILE__) -::Dir.glob(::File.expand_path('../support/*.rb', __FILE__)).each { |f| require_relative f } -::Dir.glob(::File.expand_path('../support/**/*.rb', __FILE__)).each { |f| require_relative f } -EOS + ::Dir.glob(::File.expand_path('../support/*.rb', __FILE__)).each { |f| require_relative f } + ::Dir.glob(::File.expand_path('../support/**/*.rb', __FILE__)).each { |f| require_relative f } + EOS end def create_example - create_file 'test/use_aruba_with_minitest.rb', <<-EOS -$LOAD_PATH.unshift File.expand_path('../test', __FILE__) + create_file 'test/use_aruba_with_minitest.rb', <<~EOS + $LOAD_PATH.unshift File.expand_path('../test', __FILE__) -require 'test_helper' -require 'minitest/autorun' -require 'aruba/api' + require 'test_helper' + require 'minitest/autorun' + require 'aruba/api' -class FirstRun < Minitest::Test - include Aruba::Api + class FirstRun < Minitest::Test + include Aruba::Api - def setup - aruba_setup - end -end -EOS + def setup + aruba_setup + end + end + EOS end end end diff --git a/spec/aruba/matchers/collection_spec.rb b/spec/aruba/matchers/collection_spec.rb index 95509eea5..61980e64e 100644 --- a/spec/aruba/matchers/collection_spec.rb +++ b/spec/aruba/matchers/collection_spec.rb @@ -16,8 +16,8 @@ context 'when failing' do it 'emits failure messages for all candidate objects' do - expect { expect([14, 'a']).to include_an_object(be_odd) }. - to fail_with <<-MESSAGE.strip_heredoc.strip + expect { expect([14, 'a']).to include_an_object(be_odd) } + .to fail_with <<-MESSAGE.strip_heredoc.strip expected [14, "a"] to include an object be odd object at index 0 failed to match: @@ -29,13 +29,13 @@ end it 'emits plain failure message when negated' do - expect { expect([14, 'a']).not_to include_an_object(be_even) }. - to fail_with 'expected [14, "a"] not to include an object be even' + expect { expect([14, 'a']).not_to include_an_object(be_even) } + .to fail_with 'expected [14, "a"] not to include an object be even' end it 'skips boiler plate if only one candidate object is given' do - expect { expect([14]).to include_an_object(be_odd) }. - to fail_with 'expected `14.odd?` to return true, got false' + expect { expect([14]).to include_an_object(be_odd) } + .to fail_with 'expected `14.odd?` to return true, got false' end end From 48bb49cd7f5ff0bcff3ea9cf8f03612b1d62c212 Mon Sep 17 00:00:00 2001 From: Luke Hill Date: Mon, 1 Jul 2019 13:09:16 +0200 Subject: [PATCH 2/8] Fixed up the names of a couple of constants/memos --- lib/aruba/api/core.rb | 2 +- lib/aruba/platform.rb | 12 ++---------- 2 files changed, 3 insertions(+), 11 deletions(-) diff --git a/lib/aruba/api/core.rb b/lib/aruba/api/core.rb index c98165c66..41de5d750 100644 --- a/lib/aruba/api/core.rb +++ b/lib/aruba/api/core.rb @@ -15,7 +15,7 @@ module Core # Aruba Runtime def aruba - @_aruba_runtime ||= Runtime.new + @aruba ||= Runtime.new end # Clean the working directory of aruba diff --git a/lib/aruba/platform.rb b/lib/aruba/platform.rb index b5f049b17..b0c87cfa3 100644 --- a/lib/aruba/platform.rb +++ b/lib/aruba/platform.rb @@ -4,18 +4,10 @@ # Aruba module Aruba PLATFORM_MUTEX = Mutex.new -end + PLATFORM = [Platforms::WindowsPlatform, Platforms::UnixPlatform].find(&:match?) -# Aruba -module Aruba - # Platform - Platform = [Platforms::WindowsPlatform, Platforms::UnixPlatform].find(&:match?) -end - -# Aruba -module Aruba PLATFORM_MUTEX.synchronize do - @platform = Platform.new + @platform = PLATFORM.new end class << self From a057d4ea4662be7bfcbc3a5268b8eb09eb1aa0a9 Mon Sep 17 00:00:00 2001 From: Luke Hill Date: Mon, 1 Jul 2019 13:10:16 +0200 Subject: [PATCH 3/8] Don't need to fully determine namespace when it's identical to the location --- lib/aruba/api.rb | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/aruba/api.rb b/lib/aruba/api.rb index eaebe11bf..053577e5f 100644 --- a/lib/aruba/api.rb +++ b/lib/aruba/api.rb @@ -19,11 +19,11 @@ module Aruba # Api module Api - include Aruba::Api::Core - include Aruba::Api::Commands - include Aruba::Api::Environment - include Aruba::Api::Filesystem - include Aruba::Api::Text - include Aruba::Api::Bundler + include Core + include Commands + include Environment + include Filesystem + include Text + include Bundler end end From 9359aa5d139dcc2976187e4bd36196e1c9f24f84 Mon Sep 17 00:00:00 2001 From: Luke Hill Date: Mon, 1 Jul 2019 13:11:35 +0200 Subject: [PATCH 4/8] When using expand path, use a slightly cleaner reference according to rubocop --- bin/console | 2 +- exe/aruba | 2 +- features/support/env.rb | 2 +- features/support/simplecov_setup.rb | 2 +- fixtures/cli-app/bin/aruba-test-cli | 2 +- fixtures/cli-app/cli-app.gemspec | 2 +- fixtures/cli-app/lib/cli/app.rb | 2 +- fixtures/cli-app/spec/spec_helper.rb | 2 +- fixtures/empty-app/cli-app.gemspec | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/bin/console b/bin/console index 7d4092bfa..e2739ca27 100755 --- a/bin/console +++ b/bin/console @@ -1,6 +1,6 @@ #!/usr/bin/env ruby -$LOAD_PATH.unshift File.expand_path('../../lib', __FILE__) +$LOAD_PATH.unshift File.expand_path('../lib', __dir__) require 'aruba/console' diff --git a/exe/aruba b/exe/aruba index 60fb1a82e..1b5ccc92c 100755 --- a/exe/aruba +++ b/exe/aruba @@ -1,6 +1,6 @@ #!/usr/bin/env ruby -$LOAD_PATH << File.expand_path('../../lib', __FILE__) +$LOAD_PATH << File.expand_path('../lib', __dir__) require 'aruba/cli' diff --git a/features/support/env.rb b/features/support/env.rb index 4e212b3f5..939357140 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -1,4 +1,4 @@ -$LOAD_PATH.unshift File.expand_path('../../../lib', __FILE__) +$LOAD_PATH.unshift File.expand_path('../../lib', __dir__) # Has to be the first file required so that all other files show coverage information require 'simplecov' diff --git a/features/support/simplecov_setup.rb b/features/support/simplecov_setup.rb index ce13c7ef9..64a7ba1ed 100644 --- a/features/support/simplecov_setup.rb +++ b/features/support/simplecov_setup.rb @@ -1,7 +1,7 @@ # @note this file is loaded in env.rb to setup simplecov using RUBYOPTs for child processes and @in-process require 'simplecov' -root = File.expand_path('../../../', __FILE__) +root = File.expand_path('../..', __dir__) SimpleCov.command_name(ENV['SIMPLECOV_COMMAND_NAME']) SimpleCov.root(root) diff --git a/fixtures/cli-app/bin/aruba-test-cli b/fixtures/cli-app/bin/aruba-test-cli index 4a49462ab..fa98463ab 100755 --- a/fixtures/cli-app/bin/aruba-test-cli +++ b/fixtures/cli-app/bin/aruba-test-cli @@ -1,6 +1,6 @@ #!/usr/bin/env ruby -$LOAD_PATH << File.expand_path('../../lib', __FILE__) +$LOAD_PATH << File.expand_path('../lib', __dir__) require 'cli/app' exit 0 diff --git a/fixtures/cli-app/cli-app.gemspec b/fixtures/cli-app/cli-app.gemspec index 76deb242f..8b50f4cd8 100644 --- a/fixtures/cli-app/cli-app.gemspec +++ b/fixtures/cli-app/cli-app.gemspec @@ -1,4 +1,4 @@ -lib = File.expand_path('../lib', __FILE__) +lib = File.expand_path('lib', __dir__) $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) require 'cli/app/version' diff --git a/fixtures/cli-app/lib/cli/app.rb b/fixtures/cli-app/lib/cli/app.rb index 51bc628c3..310f7b6e2 100644 --- a/fixtures/cli-app/lib/cli/app.rb +++ b/fixtures/cli-app/lib/cli/app.rb @@ -1,6 +1,6 @@ require 'cli/app/version' -::Dir.glob(File.expand_path('../**/*.rb', __FILE__)).each { |f| require_relative f } +::Dir.glob(File.expand_path('**/*.rb', __dir__)).each { |f| require_relative f } module Cli module App diff --git a/fixtures/cli-app/spec/spec_helper.rb b/fixtures/cli-app/spec/spec_helper.rb index 1aee4bb9a..b9fd64026 100644 --- a/fixtures/cli-app/spec/spec_helper.rb +++ b/fixtures/cli-app/spec/spec_helper.rb @@ -1,4 +1,4 @@ -$LOAD_PATH.unshift File.expand_path('../../lib', __FILE__) +$LOAD_PATH.unshift File.expand_path('../lib', __dir__) require 'cli/app' diff --git a/fixtures/empty-app/cli-app.gemspec b/fixtures/empty-app/cli-app.gemspec index 76deb242f..8b50f4cd8 100644 --- a/fixtures/empty-app/cli-app.gemspec +++ b/fixtures/empty-app/cli-app.gemspec @@ -1,4 +1,4 @@ -lib = File.expand_path('../lib', __FILE__) +lib = File.expand_path('lib', __dir__) $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) require 'cli/app/version' From 8942d110fed5b706c03e1186c90d7773b245231a Mon Sep 17 00:00:00 2001 From: Luke Hill Date: Mon, 1 Jul 2019 13:22:03 +0200 Subject: [PATCH 5/8] Fix issue where method_missing is defined without respond_to_missing? --- lib/aruba/in_config_wrapper.rb | 4 ++++ lib/aruba/platforms/command_monitor.rb | 8 ++++++++ 2 files changed, 12 insertions(+) diff --git a/lib/aruba/in_config_wrapper.rb b/lib/aruba/in_config_wrapper.rb index 09c91eb05..bf4479c31 100644 --- a/lib/aruba/in_config_wrapper.rb +++ b/lib/aruba/in_config_wrapper.rb @@ -20,5 +20,9 @@ def method_missing(name, *args) config[name] end + + def respond_to_missing?(*) + true + end end end diff --git a/lib/aruba/platforms/command_monitor.rb b/lib/aruba/platforms/command_monitor.rb index 8160595ee..32cc4899f 100644 --- a/lib/aruba/platforms/command_monitor.rb +++ b/lib/aruba/platforms/command_monitor.rb @@ -22,6 +22,10 @@ def nil? def method_missing(*) fail NoCommandHasBeenStoppedError, 'No last command stopped available' end + + def respond_to_missing?(*) + true + end end class DefaultLastCommandStarted @@ -32,6 +36,10 @@ def nil? def method_missing(*) fail NoCommandHasBeenStartedError, 'No last command started available' end + + def respond_to_missing?(*) + true + end end def initialize(opts = {}) From f0be290652523af049741c7ddd0242b1da59e429 Mon Sep 17 00:00:00 2001 From: Luke Hill Date: Mon, 1 Jul 2019 13:23:05 +0200 Subject: [PATCH 6/8] Regenerated todo config - Approx 25% fewer lines --- .rubocop_todo.yml | 76 ++++------------------------------------------- aruba.gemspec | 2 +- 2 files changed, 7 insertions(+), 71 deletions(-) diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index cafcb55a0..5589ffc02 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -1,33 +1,11 @@ # This configuration was generated by # `rubocop --auto-gen-config` -# on 2019-05-19 17:25:35 +0200 using RuboCop version 0.69.0. +# on 2019-07-01 13:22:17 +0200 using RuboCop version 0.69.0. # The point is for the user to remove these configuration records # one by one as the offenses are removed from the code base. # Note that changes in the inspected code, or installation of new # versions of RuboCop, may require this file to be generated again. -# Offense count: 5 -# Cop supports --auto-correct. -Layout/ClosingHeredocIndentation: - Exclude: - - 'lib/aruba/initializer.rb' - -# Offense count: 3 -# Cop supports --auto-correct. -# Configuration parameters: EnforcedStyle. -# SupportedStyles: leading, trailing -Layout/DotPosition: - Exclude: - - 'spec/aruba/matchers/collection_spec.rb' - -# Offense count: 5 -# Cop supports --auto-correct. -# Configuration parameters: EnforcedStyle. -# SupportedStyles: squiggly, active_support, powerpack, unindent -Layout/IndentHeredoc: - Exclude: - - 'lib/aruba/initializer.rb' - # Offense count: 7 Lint/AmbiguousBlockAssociation: Exclude: @@ -56,7 +34,7 @@ Lint/Void: Metrics/AbcSize: Max: 116 -# Offense count: 69 +# Offense count: 72 # Configuration parameters: CountComments, ExcludedMethods. # ExcludedMethods: refine Metrics/BlockLength: @@ -67,7 +45,7 @@ Metrics/BlockLength: Metrics/ClassLength: Max: 135 -# Offense count: 19 +# Offense count: 18 # Configuration parameters: CountComments, ExcludedMethods. Metrics/MethodLength: Max: 18 @@ -86,11 +64,6 @@ Metrics/ParameterLists: Metrics/PerceivedComplexity: Max: 10 -# Offense count: 1 -Naming/ConstantName: - Exclude: - - 'lib/aruba/platform.rb' - # Offense count: 5 # Configuration parameters: Blacklist. # Blacklist: (?-mix:(^|\s)(EO[A-Z]{1}|END)(\s|$)) @@ -98,13 +71,6 @@ Naming/HeredocDelimiterNaming: Exclude: - 'lib/aruba/initializer.rb' -# Offense count: 1 -# Configuration parameters: EnforcedStyleForLeadingUnderscores. -# SupportedStylesForLeadingUnderscores: disallowed, required, optional -Naming/MemoizedInstanceVariableName: - Exclude: - - 'lib/aruba/api/core.rb' - # Offense count: 16 # Configuration parameters: MinNameLength, AllowNamesEndingInNumbers, AllowedNames, ForbiddenNames. # AllowedNames: io, id, to, by, on, in, at, ip, db @@ -161,7 +127,7 @@ Style/CommentedKeyword: Exclude: - 'spec/aruba/api_spec.rb' -# Offense count: 13 +# Offense count: 12 Style/Documentation: Exclude: - 'spec/**/*' @@ -170,7 +136,6 @@ Style/Documentation: - 'fixtures/cli-app/lib/cli/app/suppress_simple_cov_output.rb' - 'fixtures/empty-app/lib/cli/app.rb' - 'lib/aruba/api/bundler.rb' - - 'lib/aruba/colorizer.rb' - 'lib/aruba/matchers/collection/include_an_object.rb' - 'lib/aruba/platforms/command_monitor.rb' - 'lib/aruba/setup.rb' @@ -181,21 +146,6 @@ Style/EvalWithLocation: Exclude: - 'spec/support/helpers/reporting.rb' -# Offense count: 16 -# Cop supports --auto-correct. -Style/ExpandPathArguments: - Exclude: - - 'bin/console' - - 'exe/aruba' - - 'features/support/env.rb' - - 'features/support/simplecov_setup.rb' - - 'fixtures/cli-app/bin/aruba-test-cli' - - 'fixtures/cli-app/cli-app.gemspec' - - 'fixtures/cli-app/lib/cli/app.rb' - - 'fixtures/cli-app/spec/spec_helper.rb' - - 'fixtures/empty-app/cli-app.gemspec' - - 'fixtures/empty-app/lib/cli/app.rb' - # Offense count: 84 # Configuration parameters: EnforcedStyle. # SupportedStyles: annotated, template, unannotated @@ -234,20 +184,6 @@ Style/MethodMissingSuper: - 'lib/aruba/platforms/command_monitor.rb' - 'lib/aruba/tasks/docker_helpers.rb' -# Offense count: 3 -Style/MissingRespondToMissing: - Exclude: - - 'lib/aruba/in_config_wrapper.rb' - - 'lib/aruba/platforms/command_monitor.rb' - -# Offense count: 1 -# Cop supports --auto-correct. -# Configuration parameters: EnforcedStyle. -# SupportedStyles: literals, strict -Style/MutableConstant: - Exclude: - - 'lib/aruba/colorizer.rb' - # Offense count: 4 # Cop supports --auto-correct. # Configuration parameters: Whitelist. @@ -300,7 +236,7 @@ Style/Semicolon: Exclude: - 'lib/aruba/platforms/aruba_fixed_size_file_creator.rb' -# Offense count: 44 +# Offense count: 43 # Cop supports --auto-correct. # Configuration parameters: EnforcedStyle. # SupportedStyles: only_raise, only_fail, semantic @@ -321,7 +257,7 @@ Style/StderrPuts: Style/SymbolArray: EnforcedStyle: brackets -# Offense count: 417 +# Offense count: 411 # Cop supports --auto-correct. # Configuration parameters: AutoCorrect, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns. # URISchemes: http, https diff --git a/aruba.gemspec b/aruba.gemspec index c77b86ca8..e68438bed 100644 --- a/aruba.gemspec +++ b/aruba.gemspec @@ -26,7 +26,7 @@ Gem::Specification.new do |spec| spec.add_development_dependency 'pry-doc', '~> 1.0.0' spec.add_development_dependency 'rake', '~> 12.3' spec.add_development_dependency 'rspec', '~> 3.6' - spec.add_development_dependency 'rubocop', '~> 0.69' + spec.add_development_dependency 'rubocop', '~> 0.69.0' spec.add_development_dependency 'rubocop-performance', '~> 1.1' spec.add_development_dependency 'simplecov', '~> 0.15' spec.add_development_dependency 'travis-yaml', '~> 0.2' From bc8fc135de6a266067f365820857fc10643874ce Mon Sep 17 00:00:00 2001 From: Luke Hill Date: Fri, 12 Jul 2019 14:49:39 +0200 Subject: [PATCH 7/8] Revert tweaks to aruba/platform.rb --- lib/aruba/platform.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/aruba/platform.rb b/lib/aruba/platform.rb index b0c87cfa3..c9c8ca1b6 100644 --- a/lib/aruba/platform.rb +++ b/lib/aruba/platform.rb @@ -4,10 +4,11 @@ # Aruba module Aruba PLATFORM_MUTEX = Mutex.new - PLATFORM = [Platforms::WindowsPlatform, Platforms::UnixPlatform].find(&:match?) + + Platform = [Platforms::WindowsPlatform, Platforms::UnixPlatform].find(&:match?) PLATFORM_MUTEX.synchronize do - @platform = PLATFORM.new + @platform = Platform.new end class << self From 48890a05382ede691c5e8ae6e5ddf96d1a9f38b0 Mon Sep 17 00:00:00 2001 From: Luke Hill Date: Mon, 15 Jul 2019 10:51:42 +0200 Subject: [PATCH 8/8] Revert memoized iVar name This seems to cause massive suite-wide errors when being renamed, so needs a much deeper investigation --- lib/aruba/api/core.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/aruba/api/core.rb b/lib/aruba/api/core.rb index 41de5d750..6bc1f73c2 100644 --- a/lib/aruba/api/core.rb +++ b/lib/aruba/api/core.rb @@ -15,7 +15,9 @@ module Core # Aruba Runtime def aruba - @aruba ||= Runtime.new + # TODO: Check this variable being accessed inconsistently. Should only be using the memo! + # Renaming this to `aruba` causes 100's of rspec failures. Needs a deeper dive, approach with caution! + @_aruba_runtime ||= Runtime.new end # Clean the working directory of aruba