Hi

>From my understanding the idea is to run integration tests, meaning
simulate page requests, and inputs, so you check your models,
controller and html forms
Try following up on the third example in the exercise

you should see messages in your test log (under Logs) in the same
format you see in your development.log
(Processing XXXXX, Rendering YYYYY, etc...)

Cheers

Dov.


On Jan 12, 1:01 pm, Juliano <[email protected]> wrote:
> Hi all,
>
> I'm trying to make the tasks, but I am with some doubts.
>
> # Update the title of the first post
> # Assert that the title has been changed
>
> If I understood correctly the material, the test must be so:
>
> post = posts(:one)
> assert post.update_attributes(:title => 'Homework')
>
> Is it correct?
>
> # Add another comment to the first post
> # Assert that the new comment has been added
>
> This test is the more confused. First:
>
> mypost = posts(:one)
> post '/posts/post_comment', :comment => {:post_id=>
> (:mypost).id, :comment => "homework comment"}
>
> I think that hitherto alright, but I don't know how to make the
> assert. I think that's so:
>
> assert :comment, mypost.comments.first                    # or
> assert assigns(:comment).valid?
>
> This lesson is very difficult for me. Thank in Advance for any help =)
> Juliano
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "ruby-on-rails-programming-with-passion" group.
To unsubscribe from this group, send email to
ruby-on-rails-programming-with-passion-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/ruby-on-rails-programming-with-passion?hl=en?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to