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

Fix MigratorTest#test_migrator_verbosity

Add `ActiveRecord::Migration.verbose = true`
to be sure that verbose is turned on in the test.

Related to #28865
This commit is contained in:
bogdanvlviv 2017-04-26 01:01:53 +03:00
parent 013c7d561f
commit 09c5236e5b

View file

@ -299,6 +299,7 @@ class MigratorTest < ActiveRecord::TestCase
def test_migrator_verbosity
_, migrations = sensors(3)
ActiveRecord::Migration.verbose = true
ActiveRecord::Migrator.new(:up, migrations, 1).migrate
assert_not_equal 0, ActiveRecord::Migration.message_count
@ -311,7 +312,6 @@ class MigratorTest < ActiveRecord::TestCase
def test_migrator_verbosity_off
_, migrations = sensors(3)
ActiveRecord::Migration.message_count = 0
ActiveRecord::Migration.verbose = false
ActiveRecord::Migrator.new(:up, migrations, 1).migrate
assert_equal 0, ActiveRecord::Migration.message_count