Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVinnie Okada <vokada@mrvinn.com>2015-03-07 21:23:43 +0300
committerVinnie Okada <vokada@mrvinn.com>2015-03-09 01:10:05 +0300
commit285c5341855f8af6cbea5e964e3104a4698fa450 (patch)
treea73054190f441edcda4c33715c7822caeb7800ed /spec/services/projects/update_service_spec.rb
parentcacac147de2b317d02788c5da1cdc6010f00a340 (diff)
Allow admins to override restricted visibility
Allow admins to use restricted visibility levels when creating or updating projects.
Diffstat (limited to 'spec/services/projects/update_service_spec.rb')
-rw-r--r--spec/services/projects/update_service_spec.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/spec/services/projects/update_service_spec.rb b/spec/services/projects/update_service_spec.rb
index 10dbc548e86..ea5b8813105 100644
--- a/spec/services/projects/update_service_spec.rb
+++ b/spec/services/projects/update_service_spec.rb
@@ -47,9 +47,9 @@ describe Projects::UpdateService do
context 'respect configured visibility restrictions setting' do
before(:each) do
- @restrictions = double("restrictions")
- allow(@restrictions).to receive(:restricted_visibility_levels) { [ "public" ] }
- Settings.stub_chain(:gitlab).and_return(@restrictions)
+ allow_any_instance_of(ApplicationSetting).to(
+ receive(:restricted_visibility_levels).and_return([20])
+ )
end
context 'should be private when updated to private' do