From 05fab15b6771960ab0b9350113f8c04c1ac0a58f Mon Sep 17 00:00:00 2001 From: Peter Amstutz Date: Thu, 2 Apr 2015 10:38:39 -0400 Subject: [PATCH] 5626: Add test for git_hostname configuration option. --- .../arvados/v1/repositories_controller_test.rb | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/services/api/test/functional/arvados/v1/repositories_controller_test.rb b/services/api/test/functional/arvados/v1/repositories_controller_test.rb index 128e4909d6..36d5c1df7f 100644 --- a/services/api/test/functional/arvados/v1/repositories_controller_test.rb +++ b/services/api/test/functional/arvados/v1/repositories_controller_test.rb @@ -96,6 +96,15 @@ class Arvados::V1::RepositoriesControllerTest < ActionController::TestCase "git@git.zzzzz.arvadosapi.com:active/foo.git") end + test "setting git_host changes fetch_url" do + Rails.configuration.git_host = "example.com" + authorize_with :active + get(:index) + assert_response :success + assert_includes(json_response["items"].map { |r| r["fetch_url"] }, + "git@example.com:active/foo.git") + end + test "can select push_url in index" do authorize_with :active get(:index, {select: ["uuid", "push_url"]}) -- 2.30.2