13996: Migrate tests to new config
[arvados.git] / services / api / test / functional / arvados / v1 / repositories_controller_test.rb
index b810d69939b30208a1f944981e53bd6ad995fbe3..d986ff937b6438d830d44eb5ae1cb20ee6f6991a 100644 (file)
@@ -200,15 +200,15 @@ class Arvados::V1::RepositoriesControllerTest < ActionController::TestCase
   end
 
   [
-    {cfg: :git_repo_ssh_base, cfgval: "git@example.com:", match: %r"^git@example.com:"},
-    {cfg: :git_repo_ssh_base, cfgval: true, match: %r"^git@git.zzzzz.arvadosapi.com:"},
-    {cfg: :git_repo_ssh_base, cfgval: false, refute: /^git@/ },
-    {cfg: :git_repo_https_base, cfgval: "https://example.com/", match: %r"^https://example.com/"},
-    {cfg: :git_repo_https_base, cfgval: true, match: %r"^https://git.zzzzz.arvadosapi.com/"},
-    {cfg: :git_repo_https_base, cfgval: false, refute: /^http/ },
+    {cfg: "Services.GitSSH.ExternalURL", cfgval: "git@example.com:", match: %r"^git@example.com:"},
+    {cfg: "Services.GitSSH.ExternalURL", cfgval: true, match: %r"^git@git.zzzzz.arvadosapi.com:"},
+    {cfg: "Services.GitSSH.ExternalURL", cfgval: false, refute: /^git@/ },
+    {cfg: "Services.GitHTTP.ExternalURL", cfgval: "https://example.com/", match: %r"^https://example.com/"},
+    {cfg: "Services.GitHTTP.ExternalURL", cfgval: true, match: %r"^https://git.zzzzz.arvadosapi.com/"},
+    {cfg: "Services.GitHTTP.ExternalURL", cfgval: false, refute: /^http/ },
   ].each do |expect|
     test "set #{expect[:cfg]} to #{expect[:cfgval]}" do
-      Rails.configuration.send expect[:cfg].to_s+"=", expect[:cfgval]
+      set_cfg Rails.configuration, expect[:cfg].to_s, expect[:cfgval]
       authorize_with :active
       get :index
       assert_response :success