Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save igorkasyanchuk/d1e68a846626aafa3e555f17663fe607 to your computer and use it in GitHub Desktop.
Save igorkasyanchuk/d1e68a846626aafa3e555f17663fe607 to your computer and use it in GitHub Desktop.
module FixLocalesSpecs
module ::ActionController::TestCase::Behavior
alias_method :process_without_logging, :process
def process(action, http_method = 'GET', *args)
e = Array.wrap(args).compact
e[0] ||= {}
e[0].merge!({locale: I18n.locale})
process_without_logging(action, http_method, *e)
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment