Topic: instance variables in functional tests

I have the following two lines within a particular functional test:

get :index, {}, {:user_id => users(:user_one).id}
[[[ assertions here... ]]]

get :new, {}, {}


When the 'index' action is called, I instantiate a particular instance variable named @logged_in.
When the 'new' action is called, this instance variable should not be instantiated.
However, I noticed that the @logged_in variable that was instantiated when I made the get request for 'index' is still available after making the get request for 'new'.  This seems weird to me, since if I were to do this by actually browsing to the url for the index action, and then going to the url for the new action, the instance variable would not carry over from one to the other. 

I have a workaround for this, by simply forcing that instance variable to be nil when I call the new action, but I would really like to understand why Rails is keeping instance variables instantiated between get requests in my functional tests, since this seems contrary to what actually happens when a user browses the site.. Or am I missing something here?

Re: instance variables in functional tests

no takers on this question?