Hi

Below is my functional test code

def test_should_create_county
    assert_difference('County.count') do
      post :create, :county =>
{:name=>"myname",:description=>"mydesc",:region_id=>"3" }
    end
    assert_redirected_to county_path(assigns(:county))
  end

And error message i got is

 29) Failure:
test_should_create_county(CountiesControllerTest)
[/test/functional/counties_controller_test.rb:16]:
"County.count" didn't change by 1.
<3> expected but was
<2>.


Please help

-- 
Karthik.k
Mobile - +91-9894991640

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to