Skip to content

Commit

Permalink
Change some scaffold controller template methods to let context
Browse files Browse the repository at this point in the history
  • Loading branch information
hbakhtiyor authored and alindeman committed Apr 6, 2013
1 parent 3b5d298 commit 5b3b6d7
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions lib/generators/rspec/scaffold/templates/controller_spec.rb
Expand Up @@ -24,16 +24,12 @@
# This should return the minimal set of attributes required to create a valid
# <%= class_name %>. As you add validations to <%= class_name %>, be sure to
# update the return value of this method accordingly.
def valid_attributes
<%= formatted_hash(example_valid_attributes) %>
end
let(:valid_attributes) { <%= formatted_hash(example_valid_attributes) %> }

# This should return the minimal set of values that should be in the session
# in order to pass any filters (e.g. authentication) defined in
# <%= controller_class_name %>Controller. Be sure to keep this updated too.
def valid_session
{}
end
let(:valid_session) { {} }

<% unless options[:singleton] -%>
describe "GET index" do
Expand Down

0 comments on commit 5b3b6d7

Please sign in to comment.