In the initial version of my application I am just going to require
cookies - down the road considering changing that and providing
something that works without.
Anyway, this is somewhat of a two part question
Does this approach make sense or is there a better way typically
Just have a before_filter in my application.rb to verify that the
:_session_id cookie is present. If it isn’t: kick them out to some
page that gives them the “you need cookies” message. If it’s there:
good, go ahead with whatever their request was.
Given that I am going to use the approach above: my functional
tests will need to add the :_session_id cookie before making their
requests. I am having a bit of trouble doing this. The simple
cookies[:_session_id] = “faked out”
doesn’t seem to work.
@controller.cookies is protected
Seems like I’m missing something pretty obvious this morning.
Thanks in advance