mirror of https://github.com/rails/rails
Use an appropriate rebuild task on Travis
Use `db:mysql:rebuild` when testing mysql2, `db:postgresql:rebuild` when testing postgresql and no rebuild task when testing others.
This commit is contained in:
parent
1611ab4db1
commit
bf8ca88b91
|
@ -60,7 +60,14 @@ class Build
|
|||
|
||||
def tasks
|
||||
if activerecord?
|
||||
['db:mysql:rebuild', "#{adapter}:#{'isolated_' if isolated?}test"]
|
||||
tasks = ["#{adapter}:#{'isolated_' if isolated?}test"]
|
||||
case adapter
|
||||
when 'mysql2'
|
||||
tasks.unshift 'db:mysql:rebuild'
|
||||
when 'postgresql'
|
||||
tasks.unshift 'db:postgresql:rebuild'
|
||||
end
|
||||
tasks
|
||||
else
|
||||
["test", ('isolated' if isolated?), ('integration' if integration?)].compact.join(":")
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue