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
Kerel Lacy
8,474 Pointscannot load such file -- shoulda/context (LoadError)
When I run the test "ruby -I test test/unit/user_friendship_test.rb
The command line errors out and at the type it says "cannot load such file--shoulda/context(load error)
I've looked through my gems and it says I'm using shoulda. I've also rewatched the videos. Not sure what I did wrong
9 Answers
Jason Seifer
Treehouse Guest TeacherHey Kerel, Sorry for the trouble! Can you copy and paste your Gemfile? Maybe in to a gist at https://gist.github.com/?
Kerel Lacy
8,474 PointsJason Seifer
Treehouse Guest TeacherTry running "bundle update" from your rails app directory and running the command again. Maybe the gem didn't install?
Kerel Lacy
8,474 PointsHi Jason I tried doin bundle update then running the test again. and I received the same error out messages
Kerel Lacy
8,474 PointsI also call bundle show shoulda and it says I have shoulda
/Users/KerelLacy/.rvm/gems/ruby-1.9.3-p362/gems/shoulda-3.3.2
Jason Seifer
Treehouse Guest TeacherOk, this is weird. Any chance that you have this up on GitHub or can send me a link to the repository? Or if not, can you zip up the rails app and email it over to jason@teamtreehouse.com?
Kerel Lacy
8,474 PointsHi Jason,
I sent you an email and also here is the link to the repository.
https://github.com/lacykerel/treebook.git
Thanks
Jason Seifer
Treehouse Guest TeacherOdd, this code worked fine for me. Maybe try taking the gem "shoulda-matchers" line out of your Gemfile, run "bundle" again and give it another try?
Kerel Lacy
8,474 PointsI removed shoulda matchers saved the gemfile and ran bundle again but shoulda-matchers is still showing up.
also after i updated the gem file and tried the test again I get the same errors.