summaryrefslogtreecommitdiff
path: root/spec/lib/gitlab/git_access_snippet_spec.rb
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-03-20 21:09:17 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-03-20 21:09:17 +0000
commit68f1860e6f1f9e8441c434f4e62238c359ce8c7c (patch)
treed12eab92b88fdcd0bdcea4586ec5352898b16e6c /spec/lib/gitlab/git_access_snippet_spec.rb
parent1af0d38d9c5a88d7123283c714857dc4da991371 (diff)
downloadgitlab-ce-68f1860e6f1f9e8441c434f4e62238c359ce8c7c.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/lib/gitlab/git_access_snippet_spec.rb')
-rw-r--r--spec/lib/gitlab/git_access_snippet_spec.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/spec/lib/gitlab/git_access_snippet_spec.rb b/spec/lib/gitlab/git_access_snippet_spec.rb
index f52fe8ef612..877a760152d 100644
--- a/spec/lib/gitlab/git_access_snippet_spec.rb
+++ b/spec/lib/gitlab/git_access_snippet_spec.rb
@@ -209,6 +209,16 @@ describe Gitlab::GitAccessSnippet do
expect { push_access_check }.to raise_forbidden('foo')
end
+
+ context 'when feature flag :snippet_count_check is disabled' do
+ it 'does not check push file count' do
+ stub_feature_flags(snippet_count_check: false)
+
+ expect(Gitlab::Checks::PushFileCountCheck).not_to receive(:new)
+
+ expect { push_access_check }.not_to raise_error
+ end
+ end
end
private