Browse files

- Enable rakefile to load w/o cucumber

Signed-off-by: Ryan McGeary <ryanongit@mcgeary.org>
  • Loading branch information...
1 parent bcdf8c7 commit acb71a69827d4f04555069da0784bc0e79e2d777 @zenspider zenspider committed with rmm5t Sep 12, 2010
Showing with 6 additions and 2 deletions.
  1. +6 −2 Rakefile
View
8 Rakefile
@@ -3,7 +3,11 @@ require 'rake'
require 'rake/testtask'
require 'rake/rdoctask'
require 'rake/gempackagetask'
-require 'cucumber/rake/task'
+begin
+ require 'cucumber/rake/task'
+rescue LoadError
+ warn "couldn't load cucumber, skipping"
+end
$LOAD_PATH.unshift("lib")
require 'shoulda/version'
@@ -53,7 +57,7 @@ namespace :cucumber do
t.cucumber_opts = ['--format', (ENV['CUCUMBER_FORMAT'] || 'progress')]
t.profile = 'rails3'
end
-end
+end rescue nil
desc "Run the cucumber features in both Rails 2 and 3"
task :cucumber => ["cucumber:rails2", "cucumber:rails3"]

0 comments on commit acb71a6

Please sign in to comment.