1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

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

View file

@ -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