Merge branch 'master' into 3153-auto-setup-user
[arvados.git] / services / api / test / test_helper.rb
index 47c6b613c2b85ba7f1f96fa52402fcb8bf3ab7e8..caf3e09ea3c689251d513f0a8f73ae4c623060cf 100644 (file)
@@ -48,6 +48,12 @@ class ActiveSupport::TestCase
     Thread.current[:api_client_uuid] = nil
     Thread.current[:api_client] = nil
     Thread.current[:user] = nil
+    # Restore configuration settings changed during tests
+    $application_config.each do |k,v|
+      if k.match /^[^.]*$/
+        Rails.configuration.send (k + '='), v
+      end
+    end
   end
 
   def set_user_from_auth(auth_name)