Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Stupid dirty trick to return a HTTP status code 500 when testing a Rails app
- class ApplicationController < ActionController::Base
- if Rails.env == 'test'
- rescue_from 'ActionView::TemplateError' do |exception|
- render :text => exception, :status => 500
- end
- end
- end
- # Pfffff... Doesn't work, actually!
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement