summaryrefslogtreecommitdiff
path: root/spec/requests/api/settings_spec.rb
diff options
context:
space:
mode:
authorOswaldo Ferreira <oswaldo@gitlab.com>2018-09-24 12:30:49 -0300
committerOswaldo Ferreira <oswaldo@gitlab.com>2018-10-01 11:58:21 -0300
commit4fbca2a346dc4c2c2c57e6a5bc3d13a8c3eeb23e (patch)
tree85ac3e8ffe36470fa4fa424c58e372d585417f03 /spec/requests/api/settings_spec.rb
parent4d4522c15860529693305dc0fc0231c22eaf8a31 (diff)
downloadgitlab-ce-4fbca2a346dc4c2c2c57e6a5bc3d13a8c3eeb23e.tar.gz
Make single diff patch limit configurableosw-configurable-single-diff-file-limit
- Creates a new column to hold the single patch limit value on application_settings - Allows updating this value through the application_settings API - Calculates single diff patch collapsing limit based on diff_max_patch_bytes column - Updates diff limit documentation - Adds documentation (with warning) as of how one can update this limit
Diffstat (limited to 'spec/requests/api/settings_spec.rb')
-rw-r--r--spec/requests/api/settings_spec.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/spec/requests/api/settings_spec.rb b/spec/requests/api/settings_spec.rb
index 3e0f47b84a1..e379bd9785a 100644
--- a/spec/requests/api/settings_spec.rb
+++ b/spec/requests/api/settings_spec.rb
@@ -66,7 +66,8 @@ describe API::Settings, 'Settings' do
enforce_terms: true,
terms: 'Hello world!',
performance_bar_allowed_group_path: group.full_path,
- instance_statistics_visibility_private: true
+ instance_statistics_visibility_private: true,
+ diff_max_patch_bytes: 150_000
expect(response).to have_gitlab_http_status(200)
expect(json_response['default_projects_limit']).to eq(3)
@@ -92,6 +93,7 @@ describe API::Settings, 'Settings' do
expect(json_response['terms']).to eq('Hello world!')
expect(json_response['performance_bar_allowed_group_id']).to eq(group.id)
expect(json_response['instance_statistics_visibility_private']).to be(true)
+ expect(json_response['diff_max_patch_bytes']).to eq(150_000)
end
end