diff options
author | Alejandro RodrÃguez <alejorro70@gmail.com> | 2016-06-29 23:35:00 -0400 |
---|---|---|
committer | Alejandro RodrÃguez <alejorro70@gmail.com> | 2016-06-29 23:35:00 -0400 |
commit | 4a8a69837a9a14fca39bf089099b581602d983f2 (patch) | |
tree | 79c028de4c65c580a4f5d462a3ac4202dbcd0e72 /spec/requests/api/settings_spec.rb | |
parent | 20b9bb2029972c5f5334d6d684e0d60edb034c5f (diff) | |
download | gitlab-ce-4a8a69837a9a14fca39bf089099b581602d983f2.tar.gz |
Add Application Setting to configure default Repository Path for new projectsshards-config
Diffstat (limited to 'spec/requests/api/settings_spec.rb')
-rw-r--r-- | spec/requests/api/settings_spec.rb | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/spec/requests/api/settings_spec.rb b/spec/requests/api/settings_spec.rb index f756101c514..6629a5a65e2 100644 --- a/spec/requests/api/settings_spec.rb +++ b/spec/requests/api/settings_spec.rb @@ -14,16 +14,23 @@ describe API::API, 'Settings', api: true do expect(json_response).to be_an Hash expect(json_response['default_projects_limit']).to eq(42) expect(json_response['signin_enabled']).to be_truthy + expect(json_response['repository_storage']).to eq('default') end end describe "PUT /application/settings" do + before do + storages = { 'custom' => 'tmp/tests/custom_repositories' } + allow(Gitlab.config.repositories).to receive(:storages).and_return(storages) + end + it "should update application settings" do put api("/application/settings", admin), - default_projects_limit: 3, signin_enabled: false + default_projects_limit: 3, signin_enabled: false, repository_storage: 'custom' expect(response).to have_http_status(200) expect(json_response['default_projects_limit']).to eq(3) expect(json_response['signin_enabled']).to be_falsey + expect(json_response['repository_storage']).to eq('custom') end end end |