diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2012-08-22 16:18:01 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2012-08-22 16:18:01 +0000 |
commit | 44c15c7560e83879996dd92a89347e50365f8ba7 (patch) | |
tree | dc95c72257519a022d8b824d67650d2f55735884 /test/unit/document_category_test.rb | |
parent | d1a52fd3014b9b5cf84e6b074ce072173d51f8c7 (diff) | |
download | redmine-44c15c7560e83879996dd92a89347e50365f8ba7.tar.gz redmine-44c15c7560e83879996dd92a89347e50365f8ba7.zip |
add check default document category is not defined on database in tests (#11665)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10230 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/unit/document_category_test.rb')
-rw-r--r-- | test/unit/document_category_test.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/unit/document_category_test.rb b/test/unit/document_category_test.rb index 30ef1687a..03fa1b947 100644 --- a/test/unit/document_category_test.rb +++ b/test/unit/document_category_test.rb @@ -34,12 +34,14 @@ class DocumentCategoryTest < ActiveSupport::TestCase end def test_default + assert_nil DocumentCategory.find(:first, :conditions => { :is_default => true }) e = Enumeration.find_by_name('Technical documentation') e.update_attributes(:is_default => true) assert_equal 3, DocumentCategory.default.id end def test_force_default + assert_nil DocumentCategory.find(:first, :conditions => { :is_default => true }) assert_equal 1, DocumentCategory.default.id end end |