aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/reflection_test.rb
diff options
context:
space:
mode:
authorMarcel Molina <marcel@vernix.org>2005-10-11 03:51:58 +0000
committerMarcel Molina <marcel@vernix.org>2005-10-11 03:51:58 +0000
commit31219f009cfbb1fb492f36522edc38eef667c01b (patch)
treeff4552065658811a92b213842e6ae143584e7512 /activerecord/test/reflection_test.rb
parentcb8c8070850a5d7adbe4e456b154ddf8c8f90252 (diff)
downloadrails-31219f009cfbb1fb492f36522edc38eef667c01b.tar.gz
rails-31219f009cfbb1fb492f36522edc38eef667c01b.tar.bz2
rails-31219f009cfbb1fb492f36522edc38eef667c01b.zip
Add test coverage for content_columns. Closes #2432.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2532 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/test/reflection_test.rb')
-rw-r--r--activerecord/test/reflection_test.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/activerecord/test/reflection_test.rb b/activerecord/test/reflection_test.rb
index 0935b7e5a2..c3117b8c5d 100644
--- a/activerecord/test/reflection_test.rb
+++ b/activerecord/test/reflection_test.rb
@@ -28,7 +28,10 @@ class ReflectionTest < Test::Unit::TestCase
end
def test_content_columns
- assert_equal 8, Topic.content_columns.length
+ content_columns = Topic.content_columns
+ content_column_names = content_columns.map {|column| column.name}
+ assert_equal 8, content_columns.length
+ assert_equal %w(title author_name author_email_address written_on bonus_time last_read content approved).sort, content_column_names.sort
end
def test_column_string_type_and_limit