mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 21:21:19 +08:00
DEV: correct intermittent test failure
ActionController::BadRequest can not be re-dispatched, under some conditions
we are getting this vs InvalidParameterError in the following test
59c56bd20f/spec/requests/application_controller_spec.rb (L34-L62)
This commit is contained in:
@ -20,6 +20,9 @@ module Middleware
|
||||
# the Request object has a "broken" .params which can not be accessed
|
||||
exception = nil if Rack::QueryParser::InvalidParameterError === exception
|
||||
|
||||
# We also can not dispatch bad requests as no proper params
|
||||
exception = nil if ActionController::BadRequest === exception
|
||||
|
||||
if exception
|
||||
begin
|
||||
fake_controller = ApplicationController.new
|
||||
|
Reference in New Issue
Block a user