在这个例子中,’clean_database‘任务应该在集成任务之前运行
Rake::TestTask.new(:integration) do |t| t.libs << "test" t.test_files = FileList['test/**/integration/**/test*.rb'] t.verbose = true end task :clean_database => [:init] do #... end
task :integration => :clean_database