aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases/migrator_test.rb
diff options
context:
space:
mode:
authoryui-knk <spiketeika@gmail.com>2015-09-12 23:00:57 +0900
committeryui-knk <spiketeika@gmail.com>2015-11-09 23:13:23 +0900
commit7429633b824cf8aaeea52d11876e7bd2b8d2f256 (patch)
treeaad38b660d637c8d9578955eb136337e60fb2d03 /activerecord/test/cases/migrator_test.rb
parent16214d1108c31174c94503caced3855b0f6bad95 (diff)
downloadrails-7429633b824cf8aaeea52d11876e7bd2b8d2f256.tar.gz
rails-7429633b824cf8aaeea52d11876e7bd2b8d2f256.tar.bz2
rails-7429633b824cf8aaeea52d11876e7bd2b8d2f256.zip
Deprecate `#table_exists?`, `#tables` and passing arguments to `#talbes`
Reported on #21509, how views is treated by `#tables` are differ by each adapters. To fix this different behavior, after Rails 5.0 is released, deprecate `#tables`. And `#table_exists?` would check both tables and views. To make their behavior consistent with `#tables`, after Rails 5.0 is released, deprecate `#table_exists?`.
Diffstat (limited to 'activerecord/test/cases/migrator_test.rb')
-rw-r--r--activerecord/test/cases/migrator_test.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/test/cases/migrator_test.rb b/activerecord/test/cases/migrator_test.rb
index 2ff6938e7b..dbf088f455 100644
--- a/activerecord/test/cases/migrator_test.rb
+++ b/activerecord/test/cases/migrator_test.rb
@@ -313,9 +313,9 @@ class MigratorTest < ActiveRecord::TestCase
_, migrator = migrator_class(3)
ActiveRecord::Base.connection.drop_table "schema_migrations", if_exists: true
- assert_not ActiveRecord::Base.connection.table_exists?('schema_migrations')
+ ActiveSupport::Deprecation.silence { assert_not ActiveRecord::Base.connection.table_exists?('schema_migrations') }
migrator.migrate("valid", 1)
- assert ActiveRecord::Base.connection.table_exists?('schema_migrations')
+ ActiveSupport::Deprecation.silence { assert ActiveRecord::Base.connection.table_exists?('schema_migrations') }
end
def test_migrator_forward