Permalink
Switch branches/tags
Find file
Fetching contributors…
Cannot retrieve contributors at this time
28 lines (22 sloc) 851 Bytes
require "bundler"
Bundler.setup
Bundler::GemHelper.install_tasks
require 'rake'
def cmd(command)
puts command
system command
end
require File.expand_path('../spec/support/detect_rails_version', __FILE__)
# Import all our rake tasks
FileList['tasks/**/*.rake'].each { |task| import task }
# Run the specs & cukes
task :default do
# Force spec files to be loaded and ran in alphabetical order.
specs_unit = Dir['spec/unit/**/*_spec.rb'].sort.join(' ')
specs_integration = Dir['spec/integration/**/*_spec.rb'].sort.join(' ')
exit [
cmd("export RAILS=3.0.5 && export RAILS_ENV=test && bundle exec rspec #{specs_unit}"),
cmd("export RAILS=3.0.5 && export RAILS_ENV=test && bundle exec rspec #{specs_integration}"),
cmd("export RAILS=3.0.5 && export RAILS_ENV=cucumber && bundle exec cucumber features"),
].uniq == [true]
end