diff options
author | Z.J. van de Weg <zegerjan@gitlab.com> | 2016-08-05 12:35:44 +0300 |
---|---|---|
committer | Z.J. van de Weg <zegerjan@gitlab.com> | 2016-08-05 12:38:17 +0300 |
commit | 554e18ab025fcd86001faa57fab14fe3ca28a672 (patch) | |
tree | c50c0e8a1e5d41fdbbda5f3e530d128bca01cd22 /spec/requests/api/deploy_keys_spec.rb | |
parent | 460065b743a5f28d92bda71b0e778b01cd369d80 (diff) |
Create service for enabling deploy keys
Diffstat (limited to 'spec/requests/api/deploy_keys_spec.rb')
-rw-r--r-- | spec/requests/api/deploy_keys_spec.rb | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/spec/requests/api/deploy_keys_spec.rb b/spec/requests/api/deploy_keys_spec.rb index 7e7a2733f3c..7d8cc45327c 100644 --- a/spec/requests/api/deploy_keys_spec.rb +++ b/spec/requests/api/deploy_keys_spec.rb @@ -3,11 +3,14 @@ require 'spec_helper' describe API::API, api: true do include ApiHelpers - let(:user) { create(:user) } - let(:admin) { create(:admin) } - let(:project) { create(:project, creator_id: user.id) } - let!(:deploy_keys_project) { create(:deploy_keys_project, project: project) } - let(:deploy_key) { deploy_keys_project.deploy_key } + let(:user) { create(:user) } + let(:admin) { create(:admin) } + let(:project) { create(:project, creator_id: user.id) } + let(:deploy_key) { create(:deploy_key, public: true) } + + let!(:deploy_keys_project) do + create(:deploy_keys_project, project: project, deploy_key: deploy_key) + end describe 'GET /deploy_keys' do context 'when unauthenticated' do |