Sha256: 12108650c6123b1e8c68c007703ad75b8f5853402129245d099991adc2b66f62
Contents?: true
Size: 849 Bytes
Versions: 1
Compression:
Stored size: 849 Bytes
Contents
# Copyright (c) 2006 Michael Fellinger m.fellinger@gmail.com # All files in this distribution are subject to the terms of the Ruby license. require 'spec/helper' class TCPartialHelperController < Ramaze::Controller map '/' helper :partial template_root(__DIR__/:template) def index '<html><head><title>#{render_partial("/title")}</title></head></html>' end def title "Title" end def composed @here = 'there' 'From Action | ' + render_template("partial.xhtml") end end describe "PartialHelper" do before :all do ramaze end it "should render partials" do get('/').body.should == '<html><head><title>Title</title></head></html>' end it 'should be able to render a template in the current scope' do get('/composed').body.should == 'From Action | From Partial there' end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ramaze-0.1.4 | spec/ramaze/helper/partial.rb |