From 1f933b0f855b0270ed19c8bcdcb1e3d5a7965504 Mon Sep 17 00:00:00 2001 From: Matijs van Zuijlen Date: Fri, 2 Feb 2018 13:51:39 +0100 Subject: [PATCH] Fix syntax to work with old rubies --- lib/aruba/api/core.rb | 4 ++-- lib/aruba/cucumber/hooks.rb | 2 +- lib/aruba/setup.rb | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/aruba/api/core.rb b/lib/aruba/api/core.rb index 65e60a4b3..65b499818 100644 --- a/lib/aruba/api/core.rb +++ b/lib/aruba/api/core.rb @@ -25,8 +25,8 @@ def aruba # This will only clean up aruba's working directory to remove all # artifacts of your tests. This does NOT clean up the current working # directory. - def setup_aruba(clobber: true) - Aruba::Setup.new(aruba).call(clobber: clobber) + def setup_aruba(clobber = true) + Aruba::Setup.new(aruba).call(clobber) self end diff --git a/lib/aruba/cucumber/hooks.rb b/lib/aruba/cucumber/hooks.rb index 854f947af..98fe4dcfa 100644 --- a/lib/aruba/cucumber/hooks.rb +++ b/lib/aruba/cucumber/hooks.rb @@ -19,7 +19,7 @@ end Before('@no-clobber') do - setup_aruba(clobber: false) + setup_aruba(false) end Before('~@no-clobber') do diff --git a/lib/aruba/setup.rb b/lib/aruba/setup.rb index 1d3bf1501..ece79460c 100644 --- a/lib/aruba/setup.rb +++ b/lib/aruba/setup.rb @@ -10,10 +10,10 @@ def initialize(runtime) @runtime = runtime end - def call(clobber: true) + def call(clobber = true) return if runtime.setup_already_done? - working_directory(clobber: clobber) + working_directory(clobber) events runtime.setup_done @@ -23,7 +23,7 @@ def call(clobber: true) private - def working_directory(clobber: true) + def working_directory(clobber = true) if clobber Aruba.platform.rm File.join(runtime.config.root_directory, runtime.config.working_directory), :force => true end