Changeset 827
- Timestamp:
- 04/19/08 11:36:12 (3 months ago)
- Files:
-
- trunk/radiant/app/models/page.rb (modified) (1 diff)
- trunk/radiant/spec/models/standard_tags_spec.rb (modified) (3 diffs)
- trunk/radiant/spec/scenarios/home_page_scenario.rb (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/radiant/app/models/page.rb
r813 r827 45 45 end 46 46 alias_method_chain :layout, :inheritance 47 48 def description 49 self["description"] 50 end 51 52 def description=(value) 53 self["description"] = value 54 end 47 55 48 56 def cache? trunk/radiant/spec/models/standard_tags_spec.rb
r826 r827 557 557 describe "<r:meta>" do 558 558 it "should render <meta> tags for the description and keywords" do 559 page(:home).should render('<r:meta/>').as(%{<meta rel="description" content="The homepage" /><meta rel="keywords" content="Home, Page" />})559 page(:home).should render('<r:meta/>').as(%{<meta name="description" content="The homepage" /><meta name="keywords" content="Home, Page" />}) 560 560 end 561 561 562 562 it "should render <meta> tags with escaped values for the description and keywords" do 563 page.should render('<r:meta/ >').as(%{<meta rel="description" content="sweet & harmonious biscuits" /><meta rel="keywords" content="sweet & harmonious biscuits" />})563 page.should render('<r:meta/>').as(%{<meta name="description" content="sweet & harmonious biscuits" /><meta name="keywords" content="sweet & harmonious biscuits" />}) 564 564 end 565 565 … … 577 577 describe "<r:meta:description>" do 578 578 it "should render a <meta> tag for the description" do 579 page(:home).should render('<r:meta:description/>').as(%{<meta rel="description" content="The homepage" />})579 page(:home).should render('<r:meta:description/>').as(%{<meta name="description" content="The homepage" />}) 580 580 end 581 581 582 582 it "should render a <meta> tag with escaped value for the description" do 583 page.should render('<r:meta / >').as(%{<meta rel="description" content="sweet & harmonious biscuits" />})583 page.should render('<r:meta:description />').as(%{<meta name="description" content="sweet & harmonious biscuits" />}) 584 584 end 585 585 … … 597 597 describe "<r:meta:keywords>" do 598 598 it "should render a <meta> tag for the keywords" do 599 page(:home).should render('<r:meta:keywords/>').as(%{<meta rel="keywords" content="Home, Page" />})599 page(:home).should render('<r:meta:keywords/>').as(%{<meta name="keywords" content="Home, Page" />}) 600 600 end 601 601 602 602 it "should render a <meta> tag with escaped value for the keywords" do 603 page.should render('<r:meta / >').as(%{<meta rel="keywords" content="sweet & harmonious biscuits" />})603 page.should render('<r:meta:keywords />').as(%{<meta name="keywords" content="sweet & harmonious biscuits" />}) 604 604 end 605 605 trunk/radiant/spec/scenarios/home_page_scenario.rb
r826 r827 4 4 create_page "Home", :slug => "/", :parent_id => nil, 5 5 :description => "The homepage", 6 :keywords => " home, page" do6 :keywords => "Home, Page" do 7 7 create_page_part "body", :content => "Hello world!" 8 8 create_page_part "sidebar", :content => "<r:title /> sidebar."
