Joshua Partogi
2010-Mar-08 21:57 UTC
Instantiating Controller Object on Rails3 for unit testing
Dear all, I am experiencing this error when doing unit testing: Authlogic::Session::Activation::NotActivatedError: You must activate the Authlogic::Session::Base.controller with a controller object before creating objects I know this is not an error from Rails but I encounter this when doing unit testing in Rails. This error happenned because my model has dependencies to 3rd Party library named Authlogic to get the current logged in user. Can anybody suggest what would be the best way to instantiate controller object, when 3rd party library requires a controller object to be instantiated? Thank you very much in advance for your help. Kind regards, -- http://twitter.com/scrum8 -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Apparently Analagous Threads
- Authlogic: Trying to login in my Cucumber test - Authlogic::Session::Activation::NotActivatedError
- in a rails3 - rspec then require 'authlogic/test_case' and now I broke stuff?
- Authlogic + Rails3 - undefined method `Login' for nil:NilClass
- Any way to avoid instantiating a class twice?
- [LLVMdev] Instantiating the new Instructions from CallInst Class