diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2012-08-21 13:45:40 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2012-08-21 13:45:40 +0000 |
commit | 185ab2a0209c5b748a8f7568d7ed618a81bc5cff (patch) | |
tree | b1882b478eedccdf30031e1367e5d184797b5b5a /test | |
parent | 02fb4c3b2cbcfabb4cef86c00b6f190ddd94e412 (diff) | |
download | redmine-185ab2a0209c5b748a8f7568d7ed618a81bc5cff.tar.gz redmine-185ab2a0209c5b748a8f7568d7ed618a81bc5cff.zip |
add unit test to get default document category defined on database (#11665)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10220 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test')
-rw-r--r-- | test/unit/document_category_test.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/unit/document_category_test.rb b/test/unit/document_category_test.rb index cbdd46fc3..d3d3978bf 100644 --- a/test/unit/document_category_test.rb +++ b/test/unit/document_category_test.rb @@ -32,4 +32,10 @@ class DocumentCategoryTest < ActiveSupport::TestCase def test_option_name assert_equal :enumeration_doc_categories, DocumentCategory.new.option_name end + + def test_default + e = Enumeration.find_by_name('Technical documentation') + e.update_attributes(:is_default => true) + assert_equal 3, DocumentCategory.default.id + end end |