fixed tests

This commit is contained in:
albert
2011-02-02 16:55:36 -05:00
parent 099c75f9b6
commit c80df378d8
14 changed files with 27 additions and 23 deletions

View File

@@ -45,7 +45,9 @@ class UnapprovalsControllerTest < ActionController::TestCase
should "create a new unapproval" do
assert_difference("Unapproval.count", 1) do
post :create, {:post_id => @post.id, :reason => "xxx"}, {:user_id => @user.id}
post :create, {:unapproval => {:post_id => @post.id, :reason => "xxx"}}, {:user_id => @user.id}
assert_not_nil(assigns(:unapproval))
assert_equal([], assigns(:unapproval).errors.full_messages)
end
end
end