SOLVED!

Fred, thanks a ton. There was another fixture, roles_users, that I 
forgot to import from the old project. Which resulted in the test 
skipping the create method because of invalid user authentication.

I arrived at that by placing a breakpoint in the controller (create), 
and by examining the test log (great tip, sure to become a habit!)

All the best,
Vahagn


Frederick Cheung wrote:
> On 27 Oct 2008, at 10:43, Vahagn Hayrapetyan wrote:
> 
>>
>> Hi Fred,-
>>
>> login_as works in all other tests! And I actually test it by the puts
>> statements, it works because I can see the admin_user's id is 2, and
>> email is [EMAIL PROTECTED] This means that login_as works by loading
>> that user from the fixture:
>>
> Fair enough (although you're not actually testing that it works, just
> that that fixture exists, which is different from whether the session
> has been faked up properly or something like that).
> I'd still check your logs to see if some filter or something is
> stopping your action from running. Another possibility is a validation
> failure.
> 
> Fred

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to