Module: ActionView::Rendering

Defined in:
lib/cucumber-cinema.rb

Instance Method Summary collapse

Instance Method Details

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



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

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



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

alias_method :render_old, :render