Skip to content

Instantly share code, notes, and snippets.

@febuiles
Created June 30, 2011 22:29
Show Gist options
  • Save febuiles/1057448 to your computer and use it in GitHub Desktop.
Save febuiles/1057448 to your computer and use it in GitHub Desktop.
# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
require File.expand_path('../config/application', __FILE__)
require 'rake'
require 'whiskey_disk/rake'
require 'resque/tasks'
Haystack::Application.load_tasks
namespace :spec do
task :unit do
exec "bundle exec rspec spec/models spec/controllers spec/lib"
end
task :requests do
exec "bundle exec rspec spec/"
end
end
namespace :spec do
desc "Clean temporary inventory upload files"
task :clean_inventory_uploads do
puts "Deleting inventory upload temp files..."
Dir["tmp/inventory_upload*.csv"].each do |file|
print "."
File.delete file
end
puts "\nDone."
end
end
task :default => "spec:unit"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment