[rspec-users] Missing model attribute in cucumber test
Matt Wynne
matt at mattwynne.net
Wed Jan 14 14:18:50 EST 2009
On 14 Jan 2009, at 18:46, James Byrne wrote:
> Then I see this error:
>
> And the user named "newuser" is an administrator #
> features/app/models/users/step_definitions/user_steps.rb:24
> undefined method `user_administrator' for #<User:0x2ac26fa83e80>
> (NoMethodError)
> /usr/lib64/ruby/gems/1.8/gems/activerecord-2.2.2/lib/
> active_record/attribute_methods.rb:260:in
> `method_missing'
> ./features/app/models/users/step_definitions/user_steps.rb:26:in
> `And /user named "(.*)" is an administrator/'
> features/app/models/users/user.feature:29:in `And the user named
> "newuser" is an administrator'
Try rake db:test:prepare maybe?
Matt Wynne
http://blog.mattwynne.net
http://www.songkick.com
More information about the rspec-users
mailing list