aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases
diff options
context:
space:
mode:
authorJeremy Daer <jeremydaer@gmail.com>2016-04-17 13:35:16 -0700
committerJeremy Daer <jeremydaer@gmail.com>2016-04-18 12:42:24 -0700
commit485e7f25f29ca1ca23bb214b802cf68840dabbb6 (patch)
tree535f0c96556f268df114350891bbdce75bbe054a /activerecord/test/cases
parentb39131e8bdb65a9ee51e49d7fe8f058e702e173b (diff)
downloadrails-485e7f25f29ca1ca23bb214b802cf68840dabbb6.tar.gz
rails-485e7f25f29ca1ca23bb214b802cf68840dabbb6.tar.bz2
rails-485e7f25f29ca1ca23bb214b802cf68840dabbb6.zip
Database comments: switch to keyword args for new table options
* Switch to keyword args where we can without breaking compat. * Use add_table_options! for :options, too. * Some code polish.
Diffstat (limited to 'activerecord/test/cases')
-rw-r--r--activerecord/test/cases/comment_test.rb4
1 files changed, 1 insertions, 3 deletions
diff --git a/activerecord/test/cases/comment_test.rb b/activerecord/test/cases/comment_test.rb
index 53a490cf21..cb6f07c925 100644
--- a/activerecord/test/cases/comment_test.rb
+++ b/activerecord/test/cases/comment_test.rb
@@ -26,8 +26,7 @@ class CommentTest < ActiveRecord::TestCase
@connection.drop_table 'commenteds', if_exists: true
end
- if current_adapter?(:Mysql2Adapter, :PostgreSQLAdapter)
-
+ if ActiveRecord::Base.connection.supports_comments?
def test_column_created_in_block
Commented.reset_column_information
column = Commented.columns_hash['name']
@@ -86,6 +85,5 @@ class CommentTest < ActiveRecord::TestCase
assert_match %r[add_index\s+.+\s+comment: "\\\"Very important\\\" index that powers all the performance.\\nAnd it's fun!"], output
assert_match %r[add_index\s+.+\s+name: "idx_obvious",.+\s+comment: "We need to see obvious comments"], output
end
-
end
end