Permalink
Browse files

Merge branch 'roman-master'; commit '158a7e3f257e4249693494a62d9cb4ac…

…b8f1c8ac'

Conflicts:

	lib/merb_cucumber/merbtasks.rb
  • Loading branch information...
3 parents 9f72292 + 54432cd + 158a7e3 commit 58b97ca62fd82e43d57f9d33e4155ba9ff9d3e48 @david committed Nov 2, 2008
Showing with 8 additions and 3 deletions.
  1. +8 −3 lib/generators/cucumber/templates/lib/tasks/cucumber.rake
@@ -1,18 +1,23 @@
require 'cucumber/rake/task'
-Cucumber::Rake::Task::BINARY = Merb.root / 'bin' / 'cucumber'
-Cucumber::Rake::Task.new(:features) do |t|
+cucumber_options = proc do |t|
+ t.binary = Merb.root / 'bin' / 'cucumber'
t.cucumber_opts = "--format pretty"
end
+Cucumber::Rake::Task.new(:features, &cucumber_options)
+Cucumber::Rake::FeatureTask.new(:feature, &cucumber_options)
namespace :merb_cucumber do
task :test_env do
Merb.start_environment(:environment => "test", :adapter => 'runner')
end
end
<% if orm == :datamapper %>
-task :features => ['merb_cucumber:test_env', 'db:automigrate']
+dependencies = ['merb_cucumber:test_env', 'db:automigrate']
+task :features => dependencies
+task :feature => dependencies
<% else %>
task :features => 'merb_cucumber:test_env'
+task :feature => 'merb_cucumber:test_env'
<% end %>

0 comments on commit 58b97ca

Please sign in to comment.