Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Ruby Build a Todo List Application with Rails 4 Build a Todo List Application with Rails 4 Writing Test Helpers

Philip Bessa
Philip Bessa
5,396 Points

Are we supposed to have failures at the end of the video?

He doesn't run the rspec at the end (as opposed to doing it every time before every commit, etc.). Does this mean it's assumed we have failures and are just ignoring them until later or something?

I have 3 failures which I'm just going to list the messages for:

1) Adding todo items is successful with valid content
     Failure/Error: within("ul.todo_items") do
     Capybara::ElementNotFound:
       Unable to find css "ul.todo_items"
     # ./spec/features/todo_items/create_spec.rb:12:in `block (2 levels) in <top (required)>'

  2) Viewing todo items displays item content when a todo list has items
     Failure/Error: expect(page.all("ul.todo_items li").size).to eq(2)

       expected: 2
            got: 0

       (compared using ==)
     # ./spec/features/todo_items/index_spec.rb:24:in `block (2 levels) in <top (required)>'

  3) Viewing todo items displays the ittle of the todo list
     Failure/Error: within("h1") do
     Capybara::Ambiguous:
       Ambiguous match, found 2 elements matching css "h1"
     # ./spec/features/todo_items/index_spec.rb:8:in `block (2 levels) in <top (required)>'