From 02ca9151a043a4fefbb3f22edd05f0cd392fffaa Mon Sep 17 00:00:00 2001 From: Piotr Sarnacki Date: Tue, 1 May 2012 16:10:34 -0700 Subject: Deprecate remove_column with array as an argument --- activerecord/test/cases/migration_test.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'activerecord/test/cases') diff --git a/activerecord/test/cases/migration_test.rb b/activerecord/test/cases/migration_test.rb index 5c5c872993..8dde6c6b5a 100644 --- a/activerecord/test/cases/migration_test.rb +++ b/activerecord/test/cases/migration_test.rb @@ -873,6 +873,12 @@ if ActiveRecord::Base.connection.supports_migrations? assert_raise(ArgumentError) { Person.connection.remove_column("funny") } end + def test_remove_column_with_array_as_an_argument_is_deprecated + assert_deprecated /Passing array to remove_columns is deprecated/ do + Person.connection.remove_column("people", ["last_name", "description"]) + end + end + def test_change_type_of_not_null_column assert_nothing_raised do Topic.connection.change_column "topics", "written_on", :datetime, :null => false -- cgit v1.2.3