diff options
author | Ryuta Kamizono <kamipo@gmail.com> | 2017-02-26 01:45:04 +0900 |
---|---|---|
committer | Ryuta Kamizono <kamipo@gmail.com> | 2017-02-27 03:14:33 +0900 |
commit | 322a4a13107b66814d3d5f802c7f63bbc6dd8f93 (patch) | |
tree | 51558b692c65b75856d5867b941514678a0d09b2 /activerecord/test/cases/dirty_test.rb | |
parent | 25c3227255dee0e937e69f58f0cffbf9318948bd (diff) | |
download | rails-322a4a13107b66814d3d5f802c7f63bbc6dd8f93.tar.gz rails-322a4a13107b66814d3d5f802c7f63bbc6dd8f93.tar.bz2 rails-322a4a13107b66814d3d5f802c7f63bbc6dd8f93.zip |
Deprecate `supports_migrations?` on connection adapters
`supports_migrations?` was added at 4160b518 to determine if schema
statements (`create_table`, `drop_table`, etc) are implemented in the
adapter. But all tested databases has been supported migrations since
a4fc93c3 at least.
Diffstat (limited to 'activerecord/test/cases/dirty_test.rb')
-rw-r--r-- | activerecord/test/cases/dirty_test.rb | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/activerecord/test/cases/dirty_test.rb b/activerecord/test/cases/dirty_test.rb index a43c06cd6e..c13a962e3e 100644 --- a/activerecord/test/cases/dirty_test.rb +++ b/activerecord/test/cases/dirty_test.rb @@ -566,19 +566,17 @@ class DirtyTest < ActiveRecord::TestCase travel_back end - if ActiveRecord::Base.connection.supports_migrations? - class Testings < ActiveRecord::Base; end - def test_field_named_field - ActiveRecord::Base.connection.create_table :testings do |t| - t.string :field - end - assert_nothing_raised do - Testings.new.attributes - end - ensure - ActiveRecord::Base.connection.drop_table :testings rescue nil - ActiveRecord::Base.clear_cache! + class Testings < ActiveRecord::Base; end + def test_field_named_field + ActiveRecord::Base.connection.create_table :testings do |t| + t.string :field end + assert_nothing_raised do + Testings.new.attributes + end + ensure + ActiveRecord::Base.connection.drop_table :testings rescue nil + ActiveRecord::Base.clear_cache! end def test_datetime_attribute_can_be_updated_with_fractional_seconds |