aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/cases
diff options
context:
space:
mode:
authorMax Lapshin <max@maxidoors.ru>2009-04-20 19:47:31 +0400
committerPratik Naik <pratiknaik@gmail.com>2009-04-21 11:44:13 +0100
commitf3ac4f387dd748db349ec217030d2b13260516f1 (patch)
tree9f7bebcd267c68ff929f516700e91149552daab9 /activerecord/test/cases
parent64b33b6cf9db508d2c12394cc1a3f36c91fb2eed (diff)
downloadrails-f3ac4f387dd748db349ec217030d2b13260516f1.tar.gz
rails-f3ac4f387dd748db349ec217030d2b13260516f1.tar.bz2
rails-f3ac4f387dd748db349ec217030d2b13260516f1.zip
Fixed dumping from postgresql columns in index in wrong order. [#2515 state:resolved]
Signed-off-by: Tarmo Tänav <tarmo@itech.ee>
Diffstat (limited to 'activerecord/test/cases')
-rw-r--r--activerecord/test/cases/schema_dumper_test.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/activerecord/test/cases/schema_dumper_test.rb b/activerecord/test/cases/schema_dumper_test.rb
index 0b1a075b98..f9ad7f3ba3 100644
--- a/activerecord/test/cases/schema_dumper_test.rb
+++ b/activerecord/test/cases/schema_dumper_test.rb
@@ -152,6 +152,11 @@ class SchemaDumperTest < ActiveRecord::TestCase
end
end
+ def test_schema_dumps_index_columns_in_right_order
+ index_definition = standard_dump.split(/\n/).grep(/add_index.*companies/).first.strip
+ assert_equal 'add_index "companies", ["firm_id", "type", "rating", "ruby_type"], :name => "company_index"', index_definition
+ end
+
if current_adapter?(:MysqlAdapter)
def test_schema_dump_should_not_add_default_value_for_mysql_text_field
output = standard_dump