Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

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
       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
       Ambiguous match, found 2 elements matching css "h1"
     # ./spec/features/todo_items/index_spec.rb:8:in `block (2 levels) in <top (required)>'