Displaying 2 results from an estimated 2 matches for "base_titl".
Did you mean:
base_title
2012 Sep 09
5
Rails Syntax Change
I am a newbie. Looking at some old text vs new. I see some changes:
New: <%= yield(:title) %>
Old: <%= @title %>
New: "#{base_title} | Home"
Old: @base_title + "| Home"
Can you tell me when they got changed? Are the new syntax now the
preferred way? Are they more elegant?
Thanks!
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to...
2012 Mar 16
0
Rails tests failing
...;', content: ''View'') }
it { should have_selector(''title'', content: full_title(''View
Snippets'')) }
end
end
[/code]
I can''t understand why my tests is not working Here is the helper:
[code]
def full_title(page_title)
base_title = "Sample App"
if page_title.empty?
base_title
else
page_title
end
end
[/code]
http://stackoverflow.com/questions/9728983/rails-tests-failing/9730133#9730133
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Ta...