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

Andrew Rice
Andrew Rice
2,233 Points

Ruby on Rails track - Validating Presence video - issue with Rails v4?

I am following along with the tutorial and trying to run some tests. I am using Ruby v2+ and Rails v4+, which obviously isn't what the videos use, so this is likely the culprit. First off, I noticed in the video they say to go to the unit folder in tests and open user_test.rb. I don't have this there, mine is under the models folder.

Now, when I go to run "ruby -Itest test/models/user_test.rb" it says:

ruby: No such file or directory -- /test/models/user_test.rb (LoadError)

And if I cd in to that folder and try to run user_test.rb, it doesn't run either.

Any ideas?

Sorry, I'm an idiot. I accidentally included a / before the test...

2 Answers

Andrew Rice
Andrew Rice
2,233 Points

Yeah all good, thanks.