diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2010-09-29 11:18:43 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2010-09-29 11:18:43 -0700 |
commit | 5793d5e0023257962ed9a8ef980062cddd30ce19 (patch) | |
tree | f5b48497144a7876448a45e624fa78e6bdc3c6aa /activerecord/test | |
parent | c57f5d58ea5ba60b0997017ab322481377c81c2c (diff) | |
download | rails-5793d5e0023257962ed9a8ef980062cddd30ce19.tar.gz rails-5793d5e0023257962ed9a8ef980062cddd30ce19.tar.bz2 rails-5793d5e0023257962ed9a8ef980062cddd30ce19.zip |
eliminating method_missing on TableDefinition
Diffstat (limited to 'activerecord/test')
-rw-r--r-- | activerecord/test/cases/migration_test.rb | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/activerecord/test/cases/migration_test.rb b/activerecord/test/cases/migration_test.rb index 5242d78033..6e8ee95613 100644 --- a/activerecord/test/cases/migration_test.rb +++ b/activerecord/test/cases/migration_test.rb @@ -1588,13 +1588,23 @@ if ActiveRecord::Base.connection.supports_migrations? end end - if current_adapter?(:PostgreSQLAdapter) + if current_adapter?(:PostgreSQLAdapter) || current_adapter?(:SQLiteAdapter) || current_adapter?(:MysqlAdapter) || current_adapter?(:Mysql2Adapter) def test_xml_creates_xml_column + type = current_adapter?(:PostgreSQLAdapter) ? 'xml' : :text + with_new_table do |t| - t.expects(:column).with(:data, 'xml', {}) + t.expects(:column).with(:data, type, {}) t.xml :data end end + else + def test_xml_creates_xml_column + with_new_table do |t| + assert_raises(NotImplementedError) do + t.xml :data + end + end + end end protected |