Avoid db:dev_seed log print when run from its test

The db:dev_seed rake logs info as it progresses as information for the
developer. But that's not needed when ran from its tests file, and it
bloats the travis/rspec output with unnecessary information.

Now the task will always log info unless the rake task receives an
optional argument.
This commit is contained in:
Bertocq
2018-04-14 20:28:43 +02:00
parent a31b80fd76
commit fcdc24a78c
3 changed files with 6 additions and 3 deletions

View File

@@ -5,7 +5,7 @@ Rake.application.rake_require('tasks/db')
describe 'rake db:dev_seed' do
let :run_rake_task do
Rake.application.invoke_task('db:dev_seed')
Rake.application.invoke_task('db:dev_seed[avoid_log]')
end
it 'seeds the database without errors' do