Created
June 4, 2010 13:32
-
-
Save changa/425415 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 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! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment