Fix ArgumentError in GitAccess specs

This commit is contained in:
Jacob Vosmaer 2016-08-04 15:22:34 +02:00
parent b8f754dd0a
commit e55e224cd9
1 changed files with 6 additions and 6 deletions

View File

@ -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 }