Skip to content

Instantly share code, notes, and snippets.

@gustin
Created October 26, 2012 19:19
Show Gist options
  • Save gustin/3960854 to your computer and use it in GitHub Desktop.
Save gustin/3960854 to your computer and use it in GitHub Desktop.
Minitest in spec directory
require 'rake/testtask'
Rake::TestTask.new do |test_task|
test_task.libs.push 'spec'
test_task.name = 'spec'
test_task.pattern = 'spec/**/*_spec.rb'
test_task.verbose = true
end
task default: :spec
@gustin
Copy link
Author

gustin commented Oct 26, 2012

If using Rails with a database you'll want, Rake::TestTask.new(test: 'db:test:prepare')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment