Module: ActionView::Rendering

Defined in:
lib/cucumber-cinema.rb

Instance Method Summary collapse

Instance Method Details

#render(options = {}, locals = {}, &block) ⇒ Object



26
27
28
29
30
31
32
# File 'lib/cucumber-cinema.rb', line 26

def render(options = {}, locals = {}, &block)
  if CucumberCinema::ViewSelectStrategy.take_screenshot?(request)
    body = render_old(options, locals, &block)
    ::CucumberCinema::Camera.new.take_screenshot(body, :name=>screenshot_name)
  end
  render_old(options, locals, &block)
end

#render_oldObject



24
# File 'lib/cucumber-cinema.rb', line 24

alias_method :render_old, :render