vendor/gems/flexmock-0.8.5/lib/flexmock/rails/view_mocking.rb
def should_render_view(template_name=nil)
      if rails_version <= '1.2.4'
        should_render_view_prior_version_124(template_name)
      elsif rails_version <= '2.0.0'
        should_render_view_after_version_124(template_name)
      elsif rails_version < '2.2'
        should_render_view_after_version_202(template_name)
      else
        should_render_view_22x(template_name)    
      end
    end
# Declare that the Rails controller under test should render the
# named view.  If a view template name is given, it will be an
# error if the named view is not rendered during the execution of
# the contoller action.  If no template name is given, then the
# any view may be rendered. If no view is actually rendered, then
# an assertion failure will occur.
#
#  def test_my_action_does_what_it_should
#    should_render_view 'show'
#   
#    get :show, :id => 1
#
#    assert_response :success
#  end
#
Declare that the Rails controller under test should render the
named view.  If a view template name is given, it will be an
error if the named view is not rendered during the execution of
the contoller action.  If no template name is given, then the
any view may be rendered. If no view is actually rendered, then
an assertion failure will occur.






Declare that the Rails controller under test should render the named view . If a view template name is given it will be an error if the named view is not rendered during the execution of the contoller action . If no template name is given then the any view may be rendered . If no view is actually rendered then an assertion failure will occur .
def should_render_view(template_name=nil)
      if rails_version <= '1.2.4'
        should_render_view_prior_version_124(template_name)
      elsif rails_version <= '2.0.0'
        should_render_view_after_version_124(template_name)
      elsif rails_version < '2.2'
        should_render_view_after_version_202(template_name)
      else
        should_render_view_22x(template_name)    
      end
    end
def should_render_view ( template_name = nil ) if rails_version <= '1.2.4' should_render_view_prior_version_124 ( template_name ) elsif rails_version <= '2.0.0' should_render_view_after_version_124 ( template_name ) elsif rails_version < '2.2' should_render_view_after_version_202 ( template_name ) else should_render_view_22x ( template_name ) end end
Declare that the Rails controller under test should render the
named view.
Declare that the Rails controller under test should render the named view .
template_name