Skip to content

Commit

Permalink
Branching code in spec for different rails/rspec versions
Browse files Browse the repository at this point in the history
  • Loading branch information
ianwhite committed Oct 9, 2008
1 parent b0ce09d commit b655450
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion spec/controllers/inherited_controllers_spec.rb
Expand Up @@ -69,7 +69,12 @@ def sub_inside_a_response; end

it "should render :an_action" do
get :an_action
response.should render_template('inherited_spec/super/an_action')
# different rails/rspec behaviour catered for
begin
response.should render_template('an_action')
rescue
response.should render_template('inherited_spec/super/an_action')
end
end
end

Expand Down

0 comments on commit b655450

Please sign in to comment.