Skip to content

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also .

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also .
...
  • 2 commits
  • 6 files changed
  • 0 commit comments
  • 1 contributor
Commits on Feb 26, 2010
@aslakhellesoy aslakhellesoy When /^I successfully run "(.*)"$/ now prints the combined output if …
…exit status is not 0. Add bundle to list of common ruby scripts.
fae57a2
@aslakhellesoy aslakhellesoy Release 0.1.6 49663b2
Showing with 13 additions and 5 deletions.
  1. +4 −0 History.txt
  2. +1 −1 Rakefile
  3. +1 −1 aruba.gemspec
  4. +1 −1 features/exit_statuses.feature
  5. +3 −1 lib/aruba/api.rb
  6. +3 −1 lib/aruba/cucumber.rb
View
4 History.txt
@@ -1,3 +1,7 @@
+== 0.1.6
+* When /^I successfully run "(.*)"$/ now prints the combined output if exit status is not 0. (Aslak Hellesøy)
+* Add bundle to list of common ruby scripts. (Aslak Hellesøy)
+
== 0.1.5
* Added ability to map rvm versions to a specific version with config/aruba-rvm.yml. (Aslak Hellesøy)
* Check for presence of files. (Aslak Hellesøy)
View
2 Rakefile
@@ -5,7 +5,7 @@ require 'rake'
begin
require 'jeweler'
Jeweler::Tasks.new do |gem|
- gem.version = "0.1.5"
+ gem.version = "0.1.6"
gem.name = "aruba"
gem.summary = %Q{CLI Steps for Cucumber}
gem.description = %Q{CLI Steps for Cucumber, hand-crafted for you in Aruba}
View
2 aruba.gemspec
@@ -5,7 +5,7 @@
Gem::Specification.new do |s|
s.name = %q{aruba}
- s.version = "0.1.5"
+ s.version = "0.1.6"
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
s.authors = ["Aslak Helles\303\270y", "David Chelimsky"]
View
2 features/exit_statuses.feature
@@ -18,4 +18,4 @@ Feature: exit statuses
Scenario: Unsuccessfully run something
When I do aruba I successfully run "ruby -e 'exit 10'"
- Then aruba should fail with "got: 10"
+ Then aruba should fail with "Exit status was 10"
View
4 lib/aruba/api.rb
@@ -121,8 +121,10 @@ def detect_ruby(cmd)
end
end
+ COMMON_RUBY_SCRIPTS = /^(?:bundle|cucumber|gem|jeweler|rails|rake|rspec|spec)\s/
+
def detect_ruby_script(cmd)
- if cmd =~ /^(?:cucumber|gem|jeweler|rails|rake|rspec|spec)\s/
+ if cmd =~ COMMON_RUBY_SCRIPTS
"ruby -S #{cmd}"
else
cmd
View
4 lib/aruba/cucumber.rb
@@ -53,7 +53,9 @@
When /^I successfully run "(.*)"$/ do |cmd|
run(unescape(cmd))
- @last_exit_status.should == 0
+ if(@last_exit_status != 0)
+ fail("Exit status was #{@last_exit_status}. Output:\n#{combined_output}")
+ end
end
Then /^I should see "([^\"]*)"$/ do |partial_output|

No commit comments for this range

Something went wrong with that request. Please try again.