assert_response :redirect
assert_redirected_to :controller => :users, :action => :login, :referer => new_trace_path
# Now authenticated as a user with gps.trace.visibility set
user = create(:user)
create(:user_preference, :user => user, :k => "gps.trace.visibility", :v => "identifiable")
assert_response :redirect
assert_redirected_to :controller => :users, :action => :login, :referer => new_trace_path
# Now authenticated as a user with gps.trace.visibility set
user = create(:user)
create(:user_preference, :user => user, :k => "gps.trace.visibility", :v => "identifiable")