Merge pull request #41314 from etiennebarrie/fix-rake-test-db

Fix rake test:db loading in development
This commit is contained in:
Rafael França 2021-04-06 13:50:05 -04:00 committed by GitHub
commit c0a5e8db5e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -24,7 +24,10 @@ namespace :test do
task run: %w[test]
desc "Run tests quickly, but also reset db"
task db: %w[db:test:prepare test]
task :db do
success = system({ "RAILS_ENV" => ENV.fetch("RAILS_ENV", "test") }, "rake", "db:test:prepare", "test")
success || exit(false)
end
["models", "helpers", "channels", "controllers", "mailers", "integration", "jobs", "mailboxes"].each do |name|
task name => "test:prepare" do