aruba 0.11.0.pre → 0.11.0.pre2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/History.md +21 -1
- data/aruba.gemspec +1 -0
- data/features/api/command/find_command.feature +83 -0
- data/features/api/command/last_command_started.feature +50 -0
- data/features/api/command/last_command_stopped.feature +89 -0
- data/features/api/command/run.feature +259 -0
- data/features/api/command/stop.feature +53 -1
- data/features/api/text/replace_variables.feature +1 -1
- data/features/getting_started/run_commands.feature +177 -0
- data/features/matchers/file/be_existing_executable.feature +87 -0
- data/features/{integration/rspec/getting_started.feature → rspec/integration.feature} +31 -0
- data/fixtures/getting-started-app/Gemfile +1 -1
- data/lib/aruba.rb +0 -19
- data/lib/aruba/api.rb +2 -0
- data/lib/aruba/api/command.rb +103 -44
- data/lib/aruba/api/core.rb +13 -8
- data/lib/aruba/api/deprecated.rb +26 -4
- data/lib/aruba/api/environment.rb +21 -13
- data/lib/aruba/api/filesystem.rb +13 -0
- data/lib/aruba/api/rvm.rb +5 -0
- data/lib/aruba/api/text.rb +7 -1
- data/lib/aruba/aruba_path.rb +6 -0
- data/lib/aruba/basic_configuration.rb +35 -3
- data/lib/aruba/basic_configuration/option.rb +7 -0
- data/lib/aruba/cli.rb +4 -0
- data/lib/aruba/command.rb +47 -1
- data/lib/aruba/config.rb +15 -2
- data/lib/aruba/config_wrapper.rb +49 -8
- data/lib/aruba/console.rb +4 -1
- data/lib/aruba/console/help.rb +2 -0
- data/lib/aruba/contracts/absolute_path.rb +7 -0
- data/lib/aruba/contracts/enum.rb +5 -0
- data/lib/aruba/contracts/is_power_of_two.rb +9 -2
- data/lib/aruba/contracts/relative_path.rb +7 -0
- data/lib/aruba/cucumber/command.rb +6 -9
- data/lib/aruba/cucumber/file.rb +1 -1
- data/lib/aruba/cucumber/hooks.rb +36 -29
- data/lib/aruba/errors.rb +16 -1
- data/lib/aruba/events.rb +39 -0
- data/lib/aruba/extensions/string/strip.rb +1 -0
- data/lib/aruba/file_size.rb +11 -0
- data/lib/aruba/hooks.rb +2 -0
- data/lib/aruba/in_config_wrapper.rb +24 -0
- data/lib/aruba/in_process.rb +2 -0
- data/lib/aruba/initializer.rb +37 -0
- data/lib/aruba/matchers/base/base_matcher.rb +2 -0
- data/lib/aruba/matchers/base/object_formatter.rb +4 -0
- data/lib/aruba/matchers/collection/all.rb +2 -0
- data/lib/aruba/matchers/collection/include_an_object.rb +2 -0
- data/lib/aruba/matchers/command/have_exit_status.rb +1 -1
- data/lib/aruba/matchers/command/have_finished_in_time.rb +1 -10
- data/lib/aruba/matchers/command/have_output.rb +1 -10
- data/lib/aruba/matchers/command/have_output_on_stderr.rb +1 -10
- data/lib/aruba/matchers/command/have_output_on_stdout.rb +1 -10
- data/lib/aruba/matchers/file/be_an_existing_executable.rb +37 -0
- data/lib/aruba/platform.rb +4 -0
- data/lib/aruba/platforms/announcer.rb +225 -0
- data/lib/aruba/platforms/aruba_file_creator.rb +4 -0
- data/lib/aruba/platforms/aruba_fixed_size_file_creator.rb +4 -0
- data/lib/aruba/{aruba_logger.rb → platforms/aruba_logger.rb} +4 -0
- data/lib/aruba/platforms/command_monitor.rb +229 -0
- data/lib/aruba/platforms/determine_disk_usage.rb +5 -0
- data/lib/aruba/platforms/determine_file_size.rb +9 -0
- data/lib/aruba/platforms/disk_usage_calculator.rb +9 -0
- data/lib/aruba/platforms/local_environment.rb +12 -0
- data/lib/aruba/platforms/simple_table.rb +11 -0
- data/lib/aruba/platforms/unix_command_string.rb +3 -0
- data/lib/aruba/platforms/unix_environment_variables.rb +3 -0
- data/lib/aruba/platforms/unix_platform.rb +20 -2
- data/lib/aruba/platforms/unix_which.rb +6 -2
- data/lib/aruba/platforms/windows_command_string.rb +7 -0
- data/lib/aruba/platforms/windows_environment_variables.rb +2 -0
- data/lib/aruba/platforms/windows_platform.rb +3 -0
- data/lib/aruba/platforms/windows_which.rb +6 -2
- data/lib/aruba/processes/basic_process.rb +20 -5
- data/lib/aruba/processes/debug_process.rb +3 -1
- data/lib/aruba/processes/in_process.rb +18 -2
- data/lib/aruba/processes/spawn_process.rb +14 -13
- data/lib/aruba/rspec.rb +34 -23
- data/lib/aruba/runtime.rb +65 -6
- data/lib/aruba/setup.rb +87 -0
- data/lib/aruba/version.rb +1 -1
- data/spec/aruba/api_spec.rb +13 -36
- data/spec/aruba/{config_wrapper_spec.rb → in_config_wrapper_spec.rb} +1 -1
- data/spec/aruba/spawn_process_spec.rb +9 -14
- data/spec/support/configs/pry.rb +3 -0
- data/spec/support/shared_contexts/aruba.rb +1 -0
- metadata +40 -14
- data/features/getting_started/supported_programming_languages.feature +0 -89
- data/lib/aruba/announcer.rb +0 -219
- data/lib/aruba/matchers/rspec.rb +0 -0
- data/lib/aruba/process_monitor.rb +0 -201
- data/lib/aruba/processes/null_process.rb +0 -26
data/lib/aruba/config.rb
CHANGED
@@ -2,7 +2,7 @@ require 'contracts'
|
|
2
2
|
|
3
3
|
require 'aruba/version'
|
4
4
|
require 'aruba/basic_configuration'
|
5
|
-
require 'aruba/
|
5
|
+
require 'aruba/in_config_wrapper'
|
6
6
|
require 'aruba/hooks'
|
7
7
|
|
8
8
|
require 'aruba/contracts/relative_path'
|
@@ -11,8 +11,11 @@ require 'aruba/contracts/enum'
|
|
11
11
|
|
12
12
|
require 'aruba/contracts/is_power_of_two'
|
13
13
|
|
14
|
+
# Aruba
|
14
15
|
module Aruba
|
15
16
|
# Aruba Configuration
|
17
|
+
#
|
18
|
+
# This defines the configuration options of aruba
|
16
19
|
class Configuration < BasicConfiguration
|
17
20
|
if Aruba::VERSION >= '1.0.0'
|
18
21
|
option_reader :root_directory, :contract => { None => String }, :default => Dir.getwd
|
@@ -64,13 +67,21 @@ module Aruba
|
|
64
67
|
end
|
65
68
|
end
|
66
69
|
|
67
|
-
#
|
70
|
+
# Aruba
|
68
71
|
module Aruba
|
69
72
|
@config = Configuration.new
|
70
73
|
|
71
74
|
class << self
|
72
75
|
attr_reader :config
|
73
76
|
|
77
|
+
# Configure aruba
|
78
|
+
#
|
79
|
+
# @example How to configure aruba
|
80
|
+
#
|
81
|
+
# Aruba.configure do |config|
|
82
|
+
# config.<option> = <value>
|
83
|
+
# end
|
84
|
+
#
|
74
85
|
def configure(&block)
|
75
86
|
@config.configure(&block)
|
76
87
|
|
@@ -79,10 +90,12 @@ module Aruba
|
|
79
90
|
end
|
80
91
|
end
|
81
92
|
|
93
|
+
# Aruba
|
82
94
|
module Aruba
|
83
95
|
# Old Config
|
84
96
|
#
|
85
97
|
# @private
|
98
|
+
# @deprecated
|
86
99
|
class Config < Configuration
|
87
100
|
def initialize(*args)
|
88
101
|
warn('The use of "Aruba::Config" is deprecated. Use "Aruba::Configuration" instead.')
|
data/lib/aruba/config_wrapper.rb
CHANGED
@@ -1,17 +1,58 @@
|
|
1
1
|
module Aruba
|
2
|
+
# This wraps the current runtime configuration of aruba.
|
3
|
+
# If an option is changed, it notifies the event queue.
|
4
|
+
#
|
5
|
+
# This class is not meant for direct use - ConfigWrapper.new - by normal
|
6
|
+
# users.
|
7
|
+
#
|
8
|
+
# @private
|
2
9
|
class ConfigWrapper
|
3
|
-
|
4
|
-
private :config
|
10
|
+
private
|
5
11
|
|
6
|
-
|
7
|
-
|
12
|
+
attr_reader :config, :event_bus
|
13
|
+
|
14
|
+
public
|
15
|
+
|
16
|
+
# Create proxy
|
17
|
+
#
|
18
|
+
# @param [Config] config
|
19
|
+
# An aruba config object.
|
20
|
+
#
|
21
|
+
# @param [#notify] event_bus
|
22
|
+
# The event queue which should be notified.
|
23
|
+
def initialize(config, event_bus)
|
24
|
+
@config = config
|
25
|
+
@event_bus = event_bus
|
26
|
+
end
|
27
|
+
|
28
|
+
# Proxy all methods
|
29
|
+
#
|
30
|
+
# If one method ends with "=", e.g. ":option1=", then notify the event
|
31
|
+
# queue, that the user changes the value of "option1"
|
32
|
+
def method_missing(name, *args, &block)
|
33
|
+
event_bus.notify Events::ChangedConfiguration.new(:changed => { :name => name.to_s.gsub(/=$/, ''), :value => args.first }) if name.to_s.end_with? '='
|
34
|
+
|
35
|
+
config.send(name, *args, &block)
|
36
|
+
end
|
37
|
+
|
38
|
+
# Pass on respond_to?-calls
|
39
|
+
def respond_to_missing?(name, _include_private)
|
40
|
+
config.respond_to? name
|
8
41
|
end
|
9
42
|
|
10
|
-
|
11
|
-
|
12
|
-
|
43
|
+
# Compare two configs
|
44
|
+
#
|
45
|
+
# The comparism is done based on their values. No hooks are compared.
|
46
|
+
#
|
47
|
+
# Somehow `#respond_to_missing?`, `method_missing?` and `respond_to?` don't
|
48
|
+
# help here.
|
49
|
+
def ==(other)
|
50
|
+
config == other
|
51
|
+
end
|
13
52
|
|
14
|
-
|
53
|
+
# Pass on respond_to?-calls
|
54
|
+
def respond_to?(m)
|
55
|
+
config.respond_to? m
|
15
56
|
end
|
16
57
|
end
|
17
58
|
end
|
data/lib/aruba/console.rb
CHANGED
@@ -3,8 +3,12 @@ require 'irb'
|
|
3
3
|
require 'aruba/api'
|
4
4
|
require 'aruba/console/help'
|
5
5
|
|
6
|
+
# Aruba
|
6
7
|
module Aruba
|
8
|
+
# Consule
|
7
9
|
class Console
|
10
|
+
# Start the aruba console
|
11
|
+
#
|
8
12
|
# rubocop:disable Metrics/MethodLength
|
9
13
|
def start
|
10
14
|
# Start IRB with current context:
|
@@ -17,7 +21,6 @@ module Aruba
|
|
17
21
|
IRB.conf[:PROMPT] = {}
|
18
22
|
IRB.conf[:PROMPT][:ARUBA] = {
|
19
23
|
:PROMPT_I => '%N:%03n:%i> ',
|
20
|
-
:PROMPT_N => '%N:%03n:%i> ',
|
21
24
|
:PROMPT_S => '%N:%03n:%i%l ',
|
22
25
|
:PROMPT_C => '%N:%03n:%i* ',
|
23
26
|
:RETURN => "# => %s\n"
|
data/lib/aruba/console/help.rb
CHANGED
@@ -1,8 +1,15 @@
|
|
1
1
|
require 'aruba/aruba_path'
|
2
2
|
|
3
|
+
# Aruba
|
3
4
|
module Aruba
|
5
|
+
# Contracts
|
4
6
|
module Contracts
|
7
|
+
# Check if path is absolute
|
5
8
|
class AbsolutePath
|
9
|
+
# Check
|
10
|
+
#
|
11
|
+
# @param [Object] value
|
12
|
+
# The value to be checked
|
6
13
|
def self.valid?(value)
|
7
14
|
ArubaPath.new(value).absolute?
|
8
15
|
rescue
|
data/lib/aruba/contracts/enum.rb
CHANGED
@@ -1,7 +1,10 @@
|
|
1
1
|
require 'contracts'
|
2
2
|
|
3
|
+
# Aruba
|
3
4
|
module Aruba
|
5
|
+
# Contracts
|
4
6
|
module Contracts
|
7
|
+
# Enum
|
5
8
|
class Enum < ::Contracts::CallableClass
|
6
9
|
private
|
7
10
|
|
@@ -9,10 +12,12 @@ module Aruba
|
|
9
12
|
|
10
13
|
public
|
11
14
|
|
15
|
+
# Create contract
|
12
16
|
def initialize(*vals)
|
13
17
|
@vals = vals
|
14
18
|
end
|
15
19
|
|
20
|
+
# Check if value is part of array
|
16
21
|
def valid?(val)
|
17
22
|
vals.include? val
|
18
23
|
end
|
@@ -1,12 +1,19 @@
|
|
1
1
|
require 'aruba/aruba_path'
|
2
2
|
|
3
|
+
# Aruba
|
3
4
|
module Aruba
|
5
|
+
# Contracts
|
4
6
|
module Contracts
|
7
|
+
# Is value power of two
|
5
8
|
class IsPowerOfTwo
|
6
|
-
|
9
|
+
# Check value
|
10
|
+
#
|
11
|
+
# @param [Integer] value
|
12
|
+
# The value to be checked
|
13
|
+
def self.valid?(value)
|
7
14
|
# explanation for algorithm can be found here:
|
8
15
|
# http://www.exploringbinary.com/ten-ways-to-check-if-an-integer-is-a-power-of-two-in-c/
|
9
|
-
|
16
|
+
value != 0 && (value & (value - 1)) == 0 ? true : false
|
10
17
|
rescue
|
11
18
|
false
|
12
19
|
end
|
@@ -1,8 +1,15 @@
|
|
1
1
|
require 'aruba/aruba_path'
|
2
2
|
|
3
|
+
# Aruba
|
3
4
|
module Aruba
|
5
|
+
# Contracts
|
4
6
|
module Contracts
|
7
|
+
# Is value relative path
|
5
8
|
class RelativePath
|
9
|
+
# Check
|
10
|
+
#
|
11
|
+
# @param [String] value
|
12
|
+
# The path to be checked
|
6
13
|
def self.valid?(value)
|
7
14
|
ArubaPath.new(value).relative?
|
8
15
|
rescue
|
@@ -11,7 +11,7 @@ end
|
|
11
11
|
|
12
12
|
When(/^I run `([^`]*)`$/)do |cmd|
|
13
13
|
cmd = sanitize_text(cmd)
|
14
|
-
run_simple(cmd, false)
|
14
|
+
run_simple(cmd, fail_on_error: false)
|
15
15
|
end
|
16
16
|
|
17
17
|
When(/^I successfully run "(.*)"$/)do |cmd|
|
@@ -25,7 +25,7 @@ end
|
|
25
25
|
## I successfully run `sleep 29` for up to 30 seconds
|
26
26
|
When(/^I successfully run `(.*?)`(?: for up to (\d+) seconds)?$/)do |cmd, secs|
|
27
27
|
cmd = sanitize_text(cmd)
|
28
|
-
run_simple(cmd, true, secs && secs.to_i)
|
28
|
+
run_simple(cmd, fail_on_error: true, exit_timeout: secs && secs.to_i)
|
29
29
|
end
|
30
30
|
|
31
31
|
When(/^I run "([^"]*)" interactively$/) do |cmd|
|
@@ -107,9 +107,6 @@ When(/^I stop the command(?: started last)? if (output|stdout|stderr) contains:$
|
|
107
107
|
end
|
108
108
|
rescue ChildProcess::TimeoutError, TimeoutError
|
109
109
|
last_command_started.terminate
|
110
|
-
ensure
|
111
|
-
announcer.announce :stdout, last_command_started.stdout
|
112
|
-
announcer.announce :stderr, last_command_started.stderr
|
113
110
|
end
|
114
111
|
end
|
115
112
|
|
@@ -158,7 +155,7 @@ Then(/^(?:the )?(output|stderr|stdout)(?: from "([^"]*)")? should( not)? contain
|
|
158
155
|
end
|
159
156
|
|
160
157
|
commands = if cmd
|
161
|
-
[
|
158
|
+
[aruba.command_monitor.find(Aruba.platform.detect_ruby(cmd))]
|
162
159
|
else
|
163
160
|
all_commands
|
164
161
|
end
|
@@ -171,7 +168,7 @@ Then(/^(?:the )?(output|stderr|stdout)(?: from "([^"]*)")? should( not)? contain
|
|
171
168
|
|
172
169
|
if Aruba::VERSION < '1.0'
|
173
170
|
combined_output = commands.map do |c|
|
174
|
-
c.stop
|
171
|
+
c.stop
|
175
172
|
c.send(channel.to_sym).chomp
|
176
173
|
end.join("\n")
|
177
174
|
|
@@ -206,7 +203,7 @@ Then(/^(?:the )?(output|stderr|stdout)(?: from "([^"]*)")? should( not)? contain
|
|
206
203
|
end
|
207
204
|
|
208
205
|
commands = if cmd
|
209
|
-
[
|
206
|
+
[aruba.command_monitor.find(Aruba.platform.detect_ruby(cmd))]
|
210
207
|
else
|
211
208
|
all_commands
|
212
209
|
end
|
@@ -219,7 +216,7 @@ Then(/^(?:the )?(output|stderr|stdout)(?: from "([^"]*)")? should( not)? contain
|
|
219
216
|
|
220
217
|
if Aruba::VERSION < '1.0'
|
221
218
|
combined_output = commands.map do |c|
|
222
|
-
c.stop
|
219
|
+
c.stop
|
223
220
|
c.send(channel.to_sym).chomp
|
224
221
|
end.join("\n")
|
225
222
|
|
data/lib/aruba/cucumber/file.rb
CHANGED
@@ -88,7 +88,7 @@ Then(/^the following files should (not )?exist:$/) do |negated, files|
|
|
88
88
|
end
|
89
89
|
end
|
90
90
|
|
91
|
-
Then(/^(?:a|the) file(?: named)? "([^"]*)" should (not )?exist
|
91
|
+
Then(/^(?:a|the) file(?: named)? "([^"]*)" should (not )?exist(?: anymore)?$/) do |file, expect_match|
|
92
92
|
if expect_match
|
93
93
|
expect(file).not_to be_an_existing_file
|
94
94
|
else
|
data/lib/aruba/cucumber/hooks.rb
CHANGED
@@ -21,7 +21,7 @@ end
|
|
21
21
|
After do
|
22
22
|
restore_env
|
23
23
|
terminate_all_commands
|
24
|
-
|
24
|
+
aruba.command_monitor.clear
|
25
25
|
end
|
26
26
|
|
27
27
|
Before('~@no-clobber') do
|
@@ -29,85 +29,92 @@ Before('~@no-clobber') do
|
|
29
29
|
end
|
30
30
|
|
31
31
|
Before('@puts') do
|
32
|
-
announcer.mode = :puts
|
32
|
+
aruba.announcer.mode = :puts
|
33
33
|
end
|
34
34
|
|
35
35
|
Before('@announce-command') do
|
36
|
-
announcer.activate :command
|
36
|
+
aruba.announcer.activate :command
|
37
37
|
end
|
38
38
|
|
39
39
|
Before('@announce-cmd') do
|
40
40
|
Aruba.platform.deprecated 'The use of "@announce-cmd"-hook is deprecated. Please use "@announce-command"'
|
41
41
|
|
42
|
-
announcer.activate :command
|
42
|
+
aruba.announcer.activate :command
|
43
43
|
end
|
44
44
|
|
45
45
|
Before('@announce-output') do
|
46
|
-
announcer.activate :stdout
|
47
|
-
announcer.activate :stderr
|
46
|
+
aruba.announcer.activate :stdout
|
47
|
+
aruba.announcer.activate :stderr
|
48
48
|
end
|
49
49
|
|
50
50
|
Before('@announce-stdout') do
|
51
|
-
announcer.activate :stdout
|
51
|
+
aruba.announcer.activate :stdout
|
52
52
|
end
|
53
53
|
|
54
54
|
Before('@announce-stderr') do
|
55
|
-
announcer.activate :stderr
|
55
|
+
aruba.announcer.activate :stderr
|
56
56
|
end
|
57
57
|
|
58
58
|
Before('@announce-dir') do
|
59
59
|
Aruba.platform.deprecated 'The use of "@announce-dir"-hook is deprecated. Please use "@announce-directory"'
|
60
60
|
|
61
|
-
announcer.activate :directory
|
61
|
+
aruba.announcer.activate :directory
|
62
62
|
end
|
63
63
|
|
64
64
|
Before('@announce-directory') do
|
65
|
-
announcer.activate :directory
|
65
|
+
aruba.announcer.activate :directory
|
66
66
|
end
|
67
67
|
|
68
68
|
Before('@announce-stop-signal') do
|
69
|
-
announcer.activate :stop_signal
|
69
|
+
aruba.announcer.activate :stop_signal
|
70
70
|
end
|
71
71
|
|
72
72
|
Before('@announce-env') do
|
73
|
-
Aruba.platform.deprecated 'The use of "@announce-env"-hook is deprecated. Please use "@announce-
|
73
|
+
Aruba.platform.deprecated 'The use of "@announce-env"-hook is deprecated. Please use "@announce-changed-environment"'
|
74
74
|
|
75
|
-
announcer.activate :environment
|
75
|
+
aruba.announcer.activate :environment
|
76
76
|
end
|
77
77
|
|
78
78
|
Before('@announce-environment') do
|
79
|
-
Aruba.platform.deprecated '@announce-environment is deprecated. Use @announce-
|
79
|
+
Aruba.platform.deprecated '@announce-environment is deprecated. Use @announce-changed-environment instead'
|
80
80
|
|
81
|
-
announcer.activate :
|
81
|
+
aruba.announcer.activate :changed_environment
|
82
82
|
end
|
83
83
|
|
84
84
|
Before('@announce-full-environment') do
|
85
|
-
announcer.activate :full_environment
|
85
|
+
aruba.announcer.activate :full_environment
|
86
86
|
end
|
87
87
|
|
88
88
|
Before('@announce-modified-environment') do
|
89
|
-
|
89
|
+
Aruba.platform.deprecated '@announce-modified-environment is deprecated. Use @announce-changed-environment instead'
|
90
|
+
|
91
|
+
aruba.announcer.activate :changed_environment
|
92
|
+
end
|
93
|
+
|
94
|
+
Before('@announce-changed-environment') do
|
95
|
+
aruba.announcer.activate :changed_environment
|
90
96
|
end
|
91
97
|
|
92
98
|
Before('@announce-timeout') do
|
93
|
-
announcer.activate :timeout
|
99
|
+
aruba.announcer.activate :timeout
|
94
100
|
end
|
95
101
|
|
96
102
|
Before('@announce-wait-time') do
|
97
|
-
announcer.activate :wait_time
|
103
|
+
aruba.announcer.activate :wait_time
|
98
104
|
end
|
99
105
|
|
100
106
|
Before('@announce') do
|
101
|
-
announcer.activate :
|
102
|
-
announcer.activate :
|
103
|
-
announcer.activate :
|
104
|
-
announcer.activate :
|
105
|
-
announcer.activate :
|
106
|
-
announcer.activate :
|
107
|
-
announcer.activate :
|
108
|
-
announcer.activate :
|
109
|
-
announcer.activate :
|
110
|
-
announcer.activate :
|
107
|
+
aruba.announcer.activate :changed_environment
|
108
|
+
aruba.announcer.activate :command
|
109
|
+
aruba.announcer.activate :directory
|
110
|
+
aruba.announcer.activate :environment
|
111
|
+
aruba.announcer.activate :full_environment
|
112
|
+
aruba.announcer.activate :modified_environment
|
113
|
+
aruba.announcer.activate :stderr
|
114
|
+
aruba.announcer.activate :stdout
|
115
|
+
aruba.announcer.activate :stop_signal
|
116
|
+
aruba.announcer.activate :timeout
|
117
|
+
aruba.announcer.activate :wait_time
|
111
118
|
end
|
112
119
|
|
113
120
|
Before('@debug') do
|
data/lib/aruba/errors.rb
CHANGED
@@ -11,6 +11,21 @@ module Aruba
|
|
11
11
|
# Raised if one tries to use an unknown configuration option
|
12
12
|
class UnknownOptionError < ArgumentError; end
|
13
13
|
|
14
|
-
#
|
14
|
+
# Raised if command already died
|
15
15
|
class CommandAlreadyStoppedError < Error; end
|
16
|
+
|
17
|
+
# Raised if one tries to access last command started, but no command
|
18
|
+
# has been started
|
19
|
+
class NoCommandHasBeenStartedError < Error; end
|
20
|
+
|
21
|
+
# Raised if one tries to access last command stopped, but no command
|
22
|
+
# has been stopped
|
23
|
+
class NoCommandHasBeenStoppedError < Error; end
|
24
|
+
|
25
|
+
# Raised if one looked for a command, but no matching was found
|
26
|
+
class CommandNotFoundError < ArgumentError; end
|
27
|
+
|
28
|
+
# Raised if command was already started, otherwise aruba forgets about the
|
29
|
+
# previous pid and you've got hidden commands run
|
30
|
+
class CommandAlreadyStartedError < Error; end
|
16
31
|
end
|