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 Validating Length

create_spec validation will not work (github link included)

https://github.com/rishi09/todo_list/commit/c5212e2a4b3b08d63289e566bab9930ddf1c8b99

I think this has something to do with nokogiri. I copied and pasted the code directly out of the projects folder this time.

treehouse:~/projects/odot (master) $ bin/rspec spec/features/todo_lists/create_spec.rb /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/nokogiri-1.6.3.1/lib/nokogiri.rb:29:in require': cannot load such file -- nokogiri/nokogiri (LoadError) from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/nokogiri-1.6.3.1/lib/nokogiri.rb:29:inrescue in <top (required)>' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/nokogiri-1.6.3.1/lib/nokogiri.rb:25:in <top (required)>' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/capybara-2.1.0/lib/capybara.rb:2:inrequire' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/capybara-2.1.0/lib/capybara.rb:2:in <top (required)>' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:inrequire' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in block (2 levels) in require' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:ineach' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in block in require' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:ineach' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in require' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler.rb:132:inrequire' from /home/treehouse/projects/odot/config/application.rb:7:in <top (required)>' from /home/treehouse/projects/odot/config/environment.rb:2:inrequire' from /home/treehouse/projects/odot/config/environment.rb:2:in <top (required)>' from /home/treehouse/projects/odot/spec/spec_helper.rb:3:inrequire' from /home/treehouse/projects/odot/spec/spec_helper.rb:3:in <top (required)>' from /home/treehouse/projects/odot/spec/features/todo_lists/create_spec.rb:1:inrequire' from /home/treehouse/projects/odot/spec/features/todo_lists/create_spec.rb:1:in <top (required)>' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-core-2.14.8/lib/rspec/core/configuration.rb:896:inload' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-core-2.14.8/lib/rspec/core/configuration.rb:896:in block in load_spec_files' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-core-2.14.8/lib/rspec/core/configuration.rb:896:ineach' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-core-2.14.8/lib/rspec/core/configuration.rb:896:in load_spec_files' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-core-2.14.8/lib/rspec/core/command_line.rb:22:inrun' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-core-2.14.8/lib/rspec/core/runner.rb:80:in run' from /home/treehouse/.rbenv/versions/2.0.0-p353/lib/ruby/gems/2.0.0/gems/rspec-core-2.14.8/lib/rspec/core/runner.rb:17:inblock in autorun'

1 Answer

Brandon Barrette
Brandon Barrette
20,485 Points

Appears to be missing that gem. Look at my last response to your forum post. If that doesn't work, post the error you get after you've installed the gem.

Thanks Brandon. I will let you know!