Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

use example API instead of metadata

  • Loading branch information...
commit 67f5d8aed77206367c1d80f4c42f284b456feefa 1 parent ef92779
David Chelimsky dchelimsky authored
Showing with 2 additions and 6 deletions.
  1. +2 −6 lib/rspec/rails/example/view_example_group.rb
8 lib/rspec/rails/example/view_example_group.rb
View
@@ -8,14 +8,10 @@ class ViewExampleController < ActionController::Base
attr_accessor :controller_path
end
- module ViewExtensions
- def protect_against_forgery?; end
- end
-
def view
@view ||= begin
view = ActionView::Base.new(ActionController::Base.view_paths, assigns, controller)
- view.extend ViewExtensions
+ view.extend(Module.new { def protect_against_forgery?; end })
view
end
end
@@ -33,7 +29,7 @@ def response
end
def file_to_render
- running_example.metadata[:example_group][:description]
+ running_example.example_group.description
end
def controller_path
Please sign in to comment.
Something went wrong with that request. Please try again.