module Shoulda::Matchers::ActionController

def render_with_layout(expected_layout = nil)

it { should_not render_with_layout }
it { should render_with_layout(:special) }
it { should render_with_layout }

Example:

Ensures that the controller rendered with the given layout.
def render_with_layout(expected_layout = nil)
  RenderWithLayoutMatcher.new(expected_layout).in_context(self)
end