tags:

views:

929

answers:

2

in my system, users registering via rails website. i have to authenticate users from a custom application server written in ruby.

error messsage:

You must activate the Authlogic::Session::Base.controller with a controller object before creating objects (Authlogic::Session::Activation::NotActivatedError)

+2  A: 

Try this first:

Authlogic::Session::Base.controller = Authlogic::ControllerAdapters::RailsAdapter.new(self)
epid
+2  A: 

From: http://rdoc.info/projects/binarylogic/authlogic

require "authlogic/test_case" # include at the top of test_helper.rb setup :activate_authlogic # run before tests are executed UserSession.create(users(:whomever)) # logs a user in