aruba-jbb 0.2.6 → 0.2.6.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,213 @@
1
+ require 'aruba/api'
2
+
3
+ World(Aruba::Api)
4
+
5
+ Before('@disable-bundler') do
6
+ unset_bundler_env_vars
7
+ end
8
+
9
+ Before do
10
+ @__aruba_original_paths = (ENV['PATH'] || '').split(File::PATH_SEPARATOR)
11
+ ENV['PATH'] = ([File.expand_path('bin')] + @__aruba_original_paths).join(File::PATH_SEPARATOR)
12
+ end
13
+
14
+ After do
15
+ ENV['PATH'] = @__aruba_original_paths.join(File::PATH_SEPARATOR)
16
+ end
17
+
18
+ Before do
19
+ FileUtils.rm_rf(current_dir)
20
+ end
21
+
22
+ Before('@puts') do
23
+ @puts = true
24
+ end
25
+
26
+ Before('@announce-cmd') do
27
+ @announce_cmd = true
28
+ end
29
+
30
+ Before('@announce-stdout') do
31
+ @announce_stdout = true
32
+ end
33
+
34
+ Before('@announce-stderr') do
35
+ @announce_stderr = true
36
+ end
37
+
38
+ Before('@announce-dir') do
39
+ @announce_dir = true
40
+ end
41
+
42
+ Before('@announce-env') do
43
+ @announce_env = true
44
+ end
45
+
46
+ Before('@announce') do
47
+ @announce_stdout = true
48
+ @announce_stderr = true
49
+ @announce_cmd = true
50
+ @announce_dir = true
51
+ @announce_env = true
52
+ end
53
+
54
+ After do
55
+ restore_env
56
+ end
57
+
58
+ Given /^using a clean gemset "([^\"]*)"$/ do |gemset|
59
+ use_clean_gemset(gemset)
60
+ end
61
+
62
+ Given /^a directory named "([^\"]*)"$/ do |dir_name|
63
+ create_dir(dir_name)
64
+ end
65
+
66
+ Given /^a file named "([^\"]*)" with:$/ do |file_name, file_content|
67
+ create_file(file_name, file_content)
68
+ end
69
+
70
+ Given /^an empty file named "([^\"]*)"$/ do |file_name|
71
+ create_file(file_name, "")
72
+ end
73
+
74
+ When /^I write to "([^\"]*)" with:$/ do |file_name, file_content|
75
+ create_file(file_name, file_content, false)
76
+ end
77
+
78
+ When /^I overwrite "([^\"]*)" with:$/ do |file_name, file_content|
79
+ create_file(file_name, file_content, true)
80
+ end
81
+
82
+ When /^I append to "([^\"]*)" with:$/ do |file_name, file_content|
83
+ append_to_file(file_name, file_content)
84
+ end
85
+
86
+ When /^I cd to "([^\"]*)"$/ do |dir|
87
+ cd(dir)
88
+ end
89
+
90
+ When /^I run "(.*)"$/ do |cmd|
91
+ run(unescape(cmd), false)
92
+ end
93
+
94
+ When /^I successfully run "(.*)"$/ do |cmd|
95
+ run(unescape(cmd))
96
+ end
97
+
98
+ When /^I run "([^\"]*)" interactively$/ do |cmd|
99
+ run_interactive(unescape(cmd))
100
+ end
101
+
102
+ When /^I type "([^\"]*)"$/ do |input|
103
+ write_interactive(ensure_newline(input))
104
+ end
105
+
106
+ Then /^the output should contain "([^\"]*)"$/ do |partial_output|
107
+ assert_partial_output(partial_output)
108
+ end
109
+
110
+ Then /^the output should not contain "([^\"]*)"$/ do |partial_output|
111
+ combined_output.should_not =~ regexp(partial_output)
112
+ end
113
+
114
+ Then /^the output should contain:$/ do |partial_output|
115
+ combined_output.should =~ regexp(partial_output)
116
+ end
117
+
118
+ Then /^the output should not contain:$/ do |partial_output|
119
+ combined_output.should_not =~ regexp(partial_output)
120
+ end
121
+
122
+ Then /^the output should contain exactly "([^\"]*)"$/ do |exact_output|
123
+ combined_output.should == unescape(exact_output)
124
+ end
125
+
126
+ Then /^the output should contain exactly:$/ do |exact_output|
127
+ combined_output.should == exact_output
128
+ end
129
+
130
+ # "the output should match" allows regex in the partial_output, if
131
+ # you don't need regex, use "the output should contain" instead since
132
+ # that way, you don't have to escape regex characters that
133
+ # appear naturally in the output
134
+ Then /^the output should match \/([^\/]*)\/$/ do |partial_output|
135
+ combined_output.should =~ /#{partial_output}/
136
+ end
137
+
138
+ Then /^the output should match:$/ do |partial_output|
139
+ combined_output.should =~ /#{partial_output}/m
140
+ end
141
+
142
+ Then /^the exit status should be (\d+)$/ do |exit_status|
143
+ @last_exit_status.should == exit_status.to_i
144
+ end
145
+
146
+ Then /^the exit status should not be (\d+)$/ do |exit_status|
147
+ @last_exit_status.should_not == exit_status.to_i
148
+ end
149
+
150
+ Then /^it should (pass|fail) with:$/ do |pass_fail, partial_output|
151
+ self.__send__("assert_#{pass_fail}ing_with", partial_output)
152
+ end
153
+
154
+ Then /^it should (pass|fail) with regexp?:$/ do |pass_fail, partial_output|
155
+ Then "the output should match:", partial_output
156
+ if pass_fail == 'pass'
157
+ @last_exit_status.should == 0
158
+ else
159
+ @last_exit_status.should_not == 0
160
+ end
161
+ end
162
+
163
+ Then /^the stderr should contain "([^\"]*)"$/ do |partial_output|
164
+ @last_stderr.should =~ regexp(partial_output)
165
+ end
166
+
167
+ Then /^the stdout should contain "([^\"]*)"$/ do |partial_output|
168
+ @last_stdout.should =~ regexp(partial_output)
169
+ end
170
+
171
+ Then /^the stderr should not contain "([^\"]*)"$/ do |partial_output|
172
+ @last_stderr.should_not =~ regexp(partial_output)
173
+ end
174
+
175
+ Then /^the stdout should not contain "([^\"]*)"$/ do |partial_output|
176
+ @last_stdout.should_not =~ regexp(partial_output)
177
+ end
178
+
179
+ Then /^the following files should exist:$/ do |files|
180
+ check_file_presence(files.raw.map{|file_row| file_row[0]}, true)
181
+ end
182
+
183
+ Then /^the following files should not exist:$/ do |files|
184
+ check_file_presence(files.raw.map{|file_row| file_row[0]}, false)
185
+ end
186
+
187
+ Then /^the following directories should exist:$/ do |directories|
188
+ check_directory_presence(directories.raw.map{|directory_row| directory_row[0]}, true)
189
+ end
190
+
191
+ Then /^the following directories should not exist:$/ do |directories|
192
+ check_directory_presence(directories.raw.map{|directory_row| directory_row[0]}, false)
193
+ end
194
+
195
+ Then /^the file "([^\"]*)" should contain "([^\"]*)"$/ do |file, partial_content|
196
+ check_file_content(file, partial_content, true)
197
+ end
198
+
199
+ Then /^the file "([^\"]*)" should not contain "([^\"]*)"$/ do |file, partial_content|
200
+ check_file_content(file, partial_content, false)
201
+ end
202
+
203
+ Then /^the file "([^\"]*)" should contain exactly:$/ do |file, exact_content|
204
+ check_exact_file_content(file, exact_content)
205
+ end
206
+
207
+ Then /^the file "([^\"]*)" should match \/([^\/]*)\/$/ do |file, partial_content|
208
+ check_file_content(file, /#{partial_content}/, true)
209
+ end
210
+
211
+ Then /^the file "([^\"]*)" should not match \/([^\/]*)\/$/ do |file, partial_content|
212
+ check_file_content(file, /#{partial_content}/, false)
213
+ end
@@ -72,59 +72,85 @@ When /do have an empty file named "([^\"]*)"$/ do |file_name|
72
72
  end
73
73
 
74
74
 
75
- When /using rvm "([^\"]*)"$/ do |rvm_ruby_version|
76
- use_rvm(rvm_ruby_version)
75
+ When /exit status should be (\d+)$/ do |exit_status|
76
+ @last_exit_status.should == exit_status.to_i
77
77
  end
78
78
 
79
79
 
80
- When /using( an empty)? rvm gemset "([^\"]*)"$/ do |empty_gemset, rvm_gemset|
81
- use_rvm_gemset(rvm_gemset, empty_gemset)
80
+ When /exit status should not be (\d+)$/ do |exit_status|
81
+ @last_exit_status.should_not == exit_status.to_i
82
82
  end
83
83
 
84
84
 
85
- When /using rvm gemset "([^\"]*)" with Gemfile:$/ do |rvm_gemset, gemfile|
86
- use_rvm_gemset(rvm_gemset, true)
87
- install_gems(gemfile)
85
+ When /file "([^\"]*)" should contain "([^\"]*)"$/ do |file, partial_content|
86
+ check_file_content(file, partial_content, true)
88
87
  end
89
88
 
90
89
 
91
- When /rebase the directory named "([^\"]*)"$/ do |dir|
92
- rebase(dir)
90
+ When /file "([^\"]*)" should contain:$/ do |file, partial_content|
91
+ check_file_content(file, partial_content, true)
93
92
  end
94
93
 
95
94
 
96
- When /run "(.*)"$/ do |cmd|
97
- run(unescape(cmd), false)
95
+ When /file "([^\"]*)" should not contain "([^\"]*)"$/ do |file, partial_content|
96
+ check_file_content(file, partial_content, false)
98
97
  end
99
98
 
100
99
 
101
- When /run "(.*)" with errors?$/ do |cmd|
102
- run(unescape(cmd), false)
100
+ When /file "([^\"]*)" should not contain:$/ do |file, partial_content|
101
+ check_file_content(file, partial_content, false)
103
102
  end
104
103
 
105
104
 
106
- When /run "(.*)" without errors?$/ do |cmd|
107
- run(unescape(cmd), true)
105
+ When /file "([^\"]*)" should not match \/([^\/]*)\/$/ do |file, partial_content|
106
+ check_file_content(file, /#{partial_content}/, false)
107
+ end
108
+
109
+
110
+ When /file "([^\"]*)" should match \/([^\/]*)\/$/ do |file, partial_content|
111
+ check_file_content(file, /#{partial_content}/, true)
112
+ end
113
+
114
+
115
+ When /following directories should exist:$/ do |directories|
116
+ check_directory_presence(directories.raw.map{
117
+ |directory_row| directory_row[0]}, true)
118
+ end
119
+
120
+
121
+ When /following directories should not exist:$/ do |directories|
122
+ check_directory_presence(directories.raw.map{
123
+ |directory_row| directory_row[0]}, false)
124
+ end
125
+
126
+
127
+ When /following files? should exist:$/ do |files|
128
+ check_file_presence(files.raw.map{|file_row| file_row[0]}, true)
129
+ end
130
+
131
+
132
+ When /following files? should not exist:$/ do |files|
133
+ check_file_presence(files.raw.map{|file_row| file_row[0]}, false)
108
134
  end
109
135
 
110
136
 
111
137
  When /output should contain "([^\"]*)"$/ do |partial_output|
112
- combined_output.should =~ compile_and_escape(partial_output)
138
+ combined_output.should =~ regexp(partial_output)
113
139
  end
114
140
 
115
141
 
116
142
  When /output should not contain "([^\"]*)"$/ do |partial_output|
117
- combined_output.should_not =~ compile_and_escape(partial_output)
143
+ combined_output.should_not =~ regexp(partial_output)
118
144
  end
119
145
 
120
146
 
121
147
  When /output should contain:$/ do |partial_output|
122
- combined_output.should =~ compile_and_escape(partial_output)
148
+ combined_output.should =~ regexp(partial_output)
123
149
  end
124
150
 
125
151
 
126
152
  When /output should not contain:$/ do |partial_output|
127
- combined_output.should_not =~ compile_and_escape(partial_output)
153
+ combined_output.should_not =~ regexp(partial_output)
128
154
  end
129
155
 
130
156
 
@@ -152,93 +178,81 @@ When /output should match:$/ do |partial_output|
152
178
  end
153
179
 
154
180
 
155
- When /exit status should be (\d+)$/ do |exit_status|
156
- @last_exit_status.should == exit_status.to_i
157
- end
158
-
159
-
160
- When /exit status should not be (\d+)$/ do |exit_status|
161
- @last_exit_status.should_not == exit_status.to_i
162
- end
163
-
164
-
165
181
  When /rebase the directory "()"$/ do |dir|
166
182
  rebase(dir.to_a)
167
183
  end
168
184
 
169
185
 
170
- When /should (pass|fail) with:$/ do |pass_fail, partial_output|
171
- When "output should contain:", partial_output
172
- if pass_fail == 'pass'
173
- @last_exit_status.should == 0
174
- else
175
- @last_exit_status.should_not == 0
176
- end
177
- end
178
-
179
-
180
- When /stderr should be empty$/ do
181
- @last_stderr.should == ""
186
+ When /rebase the directory named "([^\"]*)"$/ do |dir|
187
+ rebase(dir)
182
188
  end
183
189
 
184
190
 
185
- When /stderr should contain "([^\"]*)"$/ do |partial_output|
186
- @last_stderr.should =~ compile_and_escape(partial_output)
191
+ When /run "(.*)"$/ do |cmd|
192
+ run(unescape(cmd), false)
187
193
  end
188
194
 
189
195
 
190
- When /stdout should contain "([^\"]*)"$/ do |partial_output|
191
- @last_stdout.should =~ compile_and_escape(partial_output)
196
+ When /run "([^\"]*)" interactively$/ do |cmd|
197
+ run_interactive(unescape(cmd))
192
198
  end
193
199
 
194
200
 
195
- When /stderr should not contain "([^\"]*)"$/ do |partial_output|
196
- @last_stderr.should_not =~ compile_and_escape(partial_output)
201
+ When /run "(.*)" with errors?$/ do |cmd|
202
+ run(unescape(cmd), false)
197
203
  end
198
204
 
199
205
 
200
- When /stdout should not contain "([^\"]*)"$/ do |partial_output|
201
- @last_stdout.should_not =~ compile_and_escape(partial_output)
206
+ When /run "(.*)" without errors?$/ do |cmd|
207
+ run(unescape(cmd), true)
202
208
  end
203
209
 
204
210
 
205
- When /following files? should exist:$/ do |files|
206
- check_file_presence(files.raw.map{|file_row| file_row[0]}, true)
211
+ When /should (pass|fail) with:$/ do |pass_fail, partial_output|
212
+ When "output should contain:", partial_output
213
+ if pass_fail == 'pass'
214
+ @last_exit_status.should == 0
215
+ else
216
+ @last_exit_status.should_not == 0
217
+ end
207
218
  end
208
219
 
209
220
 
210
- When /following files? should not exist:$/ do |files|
211
- check_file_presence(files.raw.map{|file_row| file_row[0]}, false)
221
+ When /should (pass|fail) with regexp?:$/ do |pass_fail, partial_output|
222
+ Then "the output should match:", partial_output
223
+ if pass_fail == 'pass'
224
+ @last_exit_status.should == 0
225
+ else
226
+ @last_exit_status.should_not == 0
227
+ end
212
228
  end
213
229
 
214
230
 
215
- When /following directories? should exist:$/ do |directories|
216
- check_directory_presence(directories.raw.map{
217
- |directory_row| directory_row[0]}, true)
231
+ When /stderr should be empty$/ do
232
+ @last_stderr.should == ""
218
233
  end
219
234
 
220
235
 
221
- When /following directories? should not exist:$/ do |directories|
222
- check_directory_presence(directories.raw.map{
223
- |directory_row| directory_row[0]}, false)
236
+ When /stderr should contain "([^\"]*)"$/ do |partial_output|
237
+ @last_stderr.should =~ regexp(partial_output)
224
238
  end
225
239
 
226
240
 
227
- When /file "([^\"]*)" should contain "([^\"]*)"$/ do |file, partial_content|
228
- check_file_content(file, partial_content, true)
241
+ When /stdout should contain "([^\"]*)"$/ do |partial_output|
242
+ @last_stdout.should =~ regexp(partial_output)
229
243
  end
230
244
 
231
245
 
232
- When /file "([^\"]*)" should contain:$/ do |file, partial_content|
233
- check_file_content(file, partial_content, true)
246
+ When /stderr should not contain "([^\"]*)"$/ do |partial_output|
247
+ @last_stderr.should_not =~ regexp(partial_output)
234
248
  end
235
249
 
236
250
 
237
- When /file "([^\"]*)" should not contain "([^\"]*)"$/ do |file, partial_content|
238
- check_file_content(file, partial_content, false)
251
+ When /stdout should not contain "([^\"]*)"$/ do |partial_output|
252
+ @last_stdout.should_not =~ regexp(partial_output)
239
253
  end
240
254
 
241
255
 
242
- When /file "([^\"]*)" should not contain:$/ do |file, partial_content|
243
- check_file_content(file, partial_content, false)
256
+ When /type "([^\"]*)"$/ do |input|
257
+ write_interactive(ensure_newline(input))
244
258
  end
data/lib/aruba.rb CHANGED
@@ -1 +1,3 @@
1
- require 'aruba/cucumber_steps'
1
+ require 'pathname'
2
+ lib_path = Pathname.new(File.dirname(__FILE__)).realpath.to_s + '/'
3
+ require lib_path + 'aruba/cucumber_steps'
metadata CHANGED
@@ -1,12 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aruba-jbb
3
3
  version: !ruby/object:Gem::Version
4
+ hash: 67
4
5
  prerelease: false
5
6
  segments:
6
7
  - 0
7
8
  - 2
8
9
  - 6
9
- version: 0.2.6
10
+ - 2
11
+ version: 0.2.6.2
10
12
  platform: ruby
11
13
  authors:
12
14
  - "Aslak Helles\xC3\xB8y"
@@ -16,39 +18,57 @@ autorequire:
16
18
  bindir: bin
17
19
  cert_chain: []
18
20
 
19
- date: 2010-09-02 00:00:00 -04:00
21
+ date: 2010-09-29 00:00:00 -04:00
20
22
  default_executable:
21
23
  dependencies:
22
24
  - !ruby/object:Gem::Dependency
23
- name: rspec
25
+ name: cucumber
24
26
  prerelease: false
25
27
  requirement: &id001 !ruby/object:Gem::Requirement
26
28
  none: false
27
29
  requirements:
28
- - - ">="
30
+ - - ~>
29
31
  - !ruby/object:Gem::Version
32
+ hash: 59
30
33
  segments:
31
- - 1
32
- - 3
33
34
  - 0
34
- version: 1.3.0
35
- type: :development
35
+ - 9
36
+ - 0
37
+ version: 0.9.0
38
+ type: :runtime
36
39
  version_requirements: *id001
37
40
  - !ruby/object:Gem::Dependency
38
- name: cucumber
41
+ name: background_process
39
42
  prerelease: false
40
43
  requirement: &id002 !ruby/object:Gem::Requirement
41
44
  none: false
42
45
  requirements:
43
46
  - - ">="
44
47
  - !ruby/object:Gem::Version
48
+ hash: 3
45
49
  segments:
46
50
  - 0
47
- - 8
48
- - 3
49
- version: 0.8.3
50
- type: :development
51
+ version: "0"
52
+ type: :runtime
51
53
  version_requirements: *id002
54
+ - !ruby/object:Gem::Dependency
55
+ name: rspec
56
+ prerelease: false
57
+ requirement: &id003 !ruby/object:Gem::Requirement
58
+ none: false
59
+ requirements:
60
+ - - ~>
61
+ - !ruby/object:Gem::Version
62
+ hash: 62196431
63
+ segments:
64
+ - 2
65
+ - 0
66
+ - 0
67
+ - beta
68
+ - 22
69
+ version: 2.0.0.beta.22
70
+ type: :development
71
+ version_requirements: *id003
52
72
  description: CLI Steps for Cucumber, hand-crafted for you in Aruba
53
73
  email: cukes@googlegroups.com
54
74
  executables: []
@@ -58,9 +78,13 @@ extensions: []
58
78
  extra_rdoc_files:
59
79
  - LICENSE
60
80
  - README.rdoc
81
+ - History.txt
61
82
  files:
83
+ - .bundle/config
62
84
  - .document
63
85
  - .gitignore
86
+ - .rvmrc
87
+ - Gemfile
64
88
  - History.txt
65
89
  - LICENSE
66
90
  - README.rdoc
@@ -69,12 +93,14 @@ files:
69
93
  - config/.gitignore
70
94
  - features/exit_statuses.feature
71
95
  - features/file_system_commands.feature
96
+ - features/interactive.feature
72
97
  - features/output.feature
73
- - features/running_ruby.feature
74
98
  - features/step_definitions/aruba_dev_steps.rb
75
99
  - features/support/env.rb
76
100
  - lib/aruba.rb
77
101
  - lib/aruba/api.rb
102
+ - lib/aruba/aruba_extension_steps.rb
103
+ - lib/aruba/cucumber.rb
78
104
  - lib/aruba/cucumber_steps.rb
79
105
  has_rdoc: true
80
106
  homepage: http://github.com/byrnejb/aruba
@@ -90,6 +116,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
90
116
  requirements:
91
117
  - - ">="
92
118
  - !ruby/object:Gem::Version
119
+ hash: 3
93
120
  segments:
94
121
  - 0
95
122
  version: "0"
@@ -98,6 +125,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
98
125
  requirements:
99
126
  - - ">="
100
127
  - !ruby/object:Gem::Version
128
+ hash: 3
101
129
  segments:
102
130
  - 0
103
131
  version: "0"
@@ -107,6 +135,11 @@ rubyforge_project:
107
135
  rubygems_version: 1.3.7
108
136
  signing_key:
109
137
  specification_version: 3
110
- summary: CLI Steps for Cucumber
111
- test_files: []
112
-
138
+ summary: Cucumber steps for external process testing from the CLI
139
+ test_files:
140
+ - features/exit_statuses.feature
141
+ - features/file_system_commands.feature
142
+ - features/interactive.feature
143
+ - features/output.feature
144
+ - features/step_definitions/aruba_dev_steps.rb
145
+ - features/support/env.rb
@@ -1,76 +0,0 @@
1
- @announce
2
- Feature: Running ruby
3
- In order to test a Ruby-based CLI app
4
- I want to have control over what Ruby version is used,
5
- possibly using a different Ruby than the one I launch Cucumber with.
6
-
7
- Scenario: Run with ruby 1.9.1
8
- Given I am using rvm "1.9.1"
9
- When I run "ruby -e 'puts RUBY_VERSION'"
10
- Then the output should contain "ruby-1.9.1-p378"
11
- And the output should not contain "rvm usage"
12
-
13
- Scenario: Run with ruby JRuby
14
- Given I am using rvm "jruby"
15
- When I run "ruby -e 'puts JRUBY_VERSION'"
16
- Then the output should contain "1.5.1"
17
- And the output should not contain "rvm usage"
18
-
19
- Scenario: Install gems with bundler
20
- Given I am using rvm "1.9.1"
21
- And I am using rvm gemset "a-new-gemset-where-no-gems-are-installed" with Gemfile:
22
- """
23
- source :gemcutter
24
- gem 'diff-lcs', '1.1.2'
25
- """
26
- When I run "gem list"
27
- Then the output should match:
28
- """
29
- bundler \(\d+\.+\d+\.+\d+\)
30
- diff-lcs \(\d+\.+\d+\.+\d+\)
31
- """
32
-
33
- Scenario: Find the version of ruby 1.9.1
34
- Given I am using rvm "1.9.1"
35
- When I run "ruby --version"
36
- Then the output should contain "1.9.1"
37
-
38
- Scenario: Find the version of cucumber on ruby 1.9.1
39
- Given I am using rvm "1.9.1"
40
- When I run "cucumber --version"
41
- Then the output should match /\d+\.+\d+\.+\d+/
42
-
43
- Scenario: Use current ruby
44
- When I run "ruby --version"
45
- Then the output should contain the current Ruby version
46
-
47
- Scenario: Use current ruby and a gem bin file
48
- When I run "rake --version"
49
- Then the output should contain "rake, version"
50
-
51
- # I have trouble running rvm 1.8.7 in OS X Leopard, which is
52
- # ruby-1.8.7-p249 (It segfaults rather often). However, a previous
53
- # patchlevel of 1.8.7 runs fine for me: ruby-1.8.7-tv1_8_7_174
54
- #
55
- # In order to provide some level of flexibility (and readability)
56
- # it should be possible to set up a mapping from a version specified
57
- # in Gherkin to an *actual* version.
58
- #
59
- # In order to make this scenario pass you therefore need to install
60
- # ruby-1.8.7-tv1_8_7_174 with rvm.
61
- Scenario: Specify an alias for an rvm
62
- Given I do have a file named "config/aruba-rvm.yml" with:
63
- """
64
- 1.8.7: ruby-1.8.7-tv1_8_7_174
65
- """
66
- And I am using rvm "1.8.7"
67
- When I run "ruby --version"
68
- Then the output should contain "patchlevel 174"
69
-
70
- # To verify this, make sure current rvm is *not* JRuby and run:
71
- #
72
- # ~/.rvm/rubies/jruby-1.4.0/bin/jruby -S cucumber features/running_ruby.feature -n "launched Cucumber"
73
- @jruby
74
- Scenario: Don't use rvm, but default to same Ruby as the one that launched Cucumber
75
- When I run "ruby -e 'puts JRUBY_VERSION if defined?(JRUBY_VERSION)'"
76
- Then the output should contain the JRuby version