summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Vosmaer <jacob@gitlab.com>2016-08-04 15:22:34 +0200
committerJacob Vosmaer <jacob@gitlab.com>2016-08-04 15:22:34 +0200
commite55e224cd9d5dfb3fc351374a0cd4620f8e845b9 (patch)
tree045b3e25a91096fd65eaf4a4cf1c46adf3b3a41d
parentb8f754dd0abdf437669e17a820a8e6c230afa73e (diff)
downloadgitlab-ce-e55e224cd9d5dfb3fc351374a0cd4620f8e845b9.tar.gz
Fix ArgumentError in GitAccess specs
-rw-r--r--spec/lib/gitlab/git_access_spec.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/spec/lib/gitlab/git_access_spec.rb b/spec/lib/gitlab/git_access_spec.rb
index 8447305a316..f12c9a370f7 100644
--- a/spec/lib/gitlab/git_access_spec.rb
+++ b/spec/lib/gitlab/git_access_spec.rb
@@ -19,11 +19,11 @@ describe Gitlab::GitAccess, lib: true do
end
it 'blocks ssh git push' do
- expect(@acc.check('git-receive-pack').allowed?).to be_falsey
+ expect(@acc.check('git-receive-pack', '_any').allowed?).to be_falsey
end
it 'blocks ssh git pull' do
- expect(@acc.check('git-upload-pack').allowed?).to be_falsey
+ expect(@acc.check('git-upload-pack', '_any').allowed?).to be_falsey
end
end
@@ -34,17 +34,17 @@ describe Gitlab::GitAccess, lib: true do
end
it 'blocks http push' do
- expect(@acc.check('git-receive-pack').allowed?).to be_falsey
+ expect(@acc.check('git-receive-pack', '_any').allowed?).to be_falsey
end
it 'blocks http git pull' do
- expect(@acc.check('git-upload-pack').allowed?).to be_falsey
+ expect(@acc.check('git-upload-pack', '_any').allowed?).to be_falsey
end
end
end
describe 'download_access_check' do
- subject { access.check('git-upload-pack') }
+ subject { access.check('git-upload-pack', '_any') }
describe 'master permissions' do
before { project.team << [user, :master] }
@@ -288,7 +288,7 @@ describe Gitlab::GitAccess, lib: true do
let(:actor) { key }
context 'push code' do
- subject { access.check('git-receive-pack') }
+ subject { access.check('git-receive-pack', '_any') }
context 'when project is authorized' do
before { key.projects << project }