spec/spec_helper.rb
def assigns_for_template
  assigns.inject({}) do |memo, kv|
    memo["@#{kv[0].to_s}".to_sym] = kv[1]
    memo
  end
end
# Prepends the assigns keywords with an "@" so that they will be
# instance variables when the template is rendered.
Prepends the assigns keywords with an "@" so that they will be
instance variables when the template is rendered.
Prepends the assigns keywords with an " @ " so that they will be instance variables when the template is rendered .
def assigns_for_template
  assigns.inject({}) do |memo, kv|
    memo["@#{kv[0].to_s}".to_sym] = kv[1]
    memo
  end
end
def assigns_for_template assigns . inject ( { } ) do | memo , kv | memo [ "@#{kv[0].to_s}" . to_sym ] = kv [ 1 ] memo end end
Prepends the assigns keywords with an "@" so that they will be
instance variables when the template is rendered.
Prepends the assigns keywords with an " @ " so that they will be instance variables when the template is rendered .