+ # Diagnostics suite doesn't run a server, so there's no cache to clear.
+ Rails.cache.clear unless (Rails.env == "diagnostics")
+ # Restore configuration settings changed during tests
+ $application_config.each do |k,v|
+ if k.match /^[^.]*$/
+ Rails.configuration.send (k + '='), v
+ end
+ end