diff options
author | noam <CLUSTERfoo@users.noreply.github.com> | 2014-11-17 12:54:40 -0500 |
---|---|---|
committer | noam <CLUSTERfoo@users.noreply.github.com> | 2014-12-03 11:35:40 -0500 |
commit | b64fb3020b34a8b9607802613d13e81b362dbae2 (patch) | |
tree | 3ebc4bceb70327405d55b7a2dd2306a5290115d2 /activerecord/test/cases/adapters | |
parent | 497544f0b3eba83c1385579de50a3d521188e448 (diff) | |
download | rails-b64fb3020b34a8b9607802613d13e81b362dbae2.tar.gz rails-b64fb3020b34a8b9607802613d13e81b362dbae2.tar.bz2 rails-b64fb3020b34a8b9607802613d13e81b362dbae2.zip |
Failure to rollback t.timestamps when within a change_table migration
When running the following migration:
change_table(:table_name) { |t| t/timestamps }
The following error was produced:
wrong number of arguments (2 for 1) .... /connection_adapters/abstract/schema_statements.rb:851:in `remove_timestamps'
This is due to `arguments` containing an empty hash as its second
argument.
Diffstat (limited to 'activerecord/test/cases/adapters')
-rw-r--r-- | activerecord/test/cases/adapters/mysql/active_schema_test.rb | 2 | ||||
-rw-r--r-- | activerecord/test/cases/adapters/mysql2/active_schema_test.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/test/cases/adapters/mysql/active_schema_test.rb b/activerecord/test/cases/adapters/mysql/active_schema_test.rb index 413f67da26..6577d56240 100644 --- a/activerecord/test/cases/adapters/mysql/active_schema_test.rb +++ b/activerecord/test/cases/adapters/mysql/active_schema_test.rb @@ -107,7 +107,7 @@ class ActiveSchemaTest < ActiveRecord::TestCase ActiveRecord::Base.connection.create_table :delete_me do |t| t.timestamps null: true end - ActiveRecord::Base.connection.remove_timestamps :delete_me + ActiveRecord::Base.connection.remove_timestamps :delete_me, { null: true } assert !column_present?('delete_me', 'updated_at', 'datetime') assert !column_present?('delete_me', 'created_at', 'datetime') ensure diff --git a/activerecord/test/cases/adapters/mysql2/active_schema_test.rb b/activerecord/test/cases/adapters/mysql2/active_schema_test.rb index 3d97182356..e87cd3886a 100644 --- a/activerecord/test/cases/adapters/mysql2/active_schema_test.rb +++ b/activerecord/test/cases/adapters/mysql2/active_schema_test.rb @@ -107,7 +107,7 @@ class ActiveSchemaTest < ActiveRecord::TestCase ActiveRecord::Base.connection.create_table :delete_me do |t| t.timestamps null: true end - ActiveRecord::Base.connection.remove_timestamps :delete_me + ActiveRecord::Base.connection.remove_timestamps :delete_me, { null: true } assert !column_present?('delete_me', 'updated_at', 'datetime') assert !column_present?('delete_me', 'created_at', 'datetime') ensure |