Mercurial > hg > soundsoftware-site
diff test/unit/.svn/text-base/board_test.rb.svn-base @ 117:af80e5618e9b redmine-1.1
* Update to Redmine 1.1-stable branch (Redmine SVN rev 4707)
author | Chris Cannam |
---|---|
date | Thu, 13 Jan 2011 12:53:21 +0000 |
parents | 513646585e45 |
children |
line wrap: on
line diff
--- a/test/unit/.svn/text-base/board_test.rb.svn-base Fri Nov 19 14:05:24 2010 +0000 +++ b/test/unit/.svn/text-base/board_test.rb.svn-base Thu Jan 13 12:53:21 2011 +0000 @@ -1,7 +1,7 @@ -require File.dirname(__FILE__) + '/../test_helper' +require File.expand_path('../../test_helper', __FILE__) class BoardTest < ActiveSupport::TestCase - fixtures :projects, :boards, :messages + fixtures :projects, :boards, :messages, :attachments, :watchers def setup @project = Project.find(1) @@ -23,8 +23,13 @@ def test_destroy board = Board.find(1) - assert board.destroy - # make sure that the associated messages are removed + assert_difference 'Message.count', -6 do + assert_difference 'Attachment.count', -1 do + assert_difference 'Watcher.count', -1 do + assert board.destroy + end + end + end assert_equal 0, Message.count(:conditions => {:board_id => 1}) end end