LoginSignup
0

More than 5 years have passed since last update.

heroku_san 3.0.2でdeploy前にテストを走らせる方法

Posted at

以下のコードを[RAILS_ROOT]/lib/tasksに追加するとdeploy前にテストが走ります。

heroku_hook.task
namespace :heroku do
  namespace :deploy do
    desc "Run spec before deploy"
    task :before => :environment do
      Rake::Task['spec'].invoke
    end
  end
end

spork等を適切に使うように設定すれば軽快に動くと思います。

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0