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


Testing with Ruby on Rails

I am running into trouble with my testing of my treebook application. The tests to validate the user enters first name, last name and password all worked great. But now that I am trying to get the test to work for uniquness of username by creating fixtures It keeps giving me that I have 4 errors.

It says something similar to this for every error in my console....

test_a_user_should_have_a_unique_profile_name(UserTest): ActiveRecord::StatementInvalid: SQLite3::SQLException: table users has no column named password: INSERT INTO "users" ("first_name", "last_name", "email", "profile_name", "password", "password_confirmation", "created_at", "updated_at", "id") VALUES ('Jeff', 'Davis', 'jtdavis911@gmail.com', 'jdavis', 'password', 'password', '2013-04-15 06:49:32', '2013-04-15 06:49:32', 750111230)

I cant seem to get this error to go away no matter what I do. if anyone had any ideas that would be awesome. Thank You!

3 Answers

Jason Seifer
Jason Seifer
Treehouse Guest Teacher

Hey Jeffery,

Try opening up the test/fixtures/users.yml file and remove the password and password_confirmation lines and let us know if that helps.

perfect yeah that worked! Just a quick question though. Why wouldn't it work the way you have it in the tutorial?

William Peterson
William Peterson
5,103 Points

I cant believe 11 months or more has passed by and this and many other errors with the ruby on rails course have not been fixed yet.

Come on Team Treehouse, let's get on the ball. People are paying for these courses! (our money = your Pay) Get it?