diff options
author | Kamil Trzcinski <ayufan@ayufan.eu> | 2015-12-04 14:55:23 +0300 |
---|---|---|
committer | Kamil Trzcinski <ayufan@ayufan.eu> | 2015-12-11 20:02:09 +0300 |
commit | e80e3f5372d6bcad1fbe04a85b3086bb66794828 (patch) | |
tree | 16b1539cfd158ecac7fe05d595cbba30b8bc1a04 /spec/lib/gitlab/backend | |
parent | 8b4cdc50fca816b4f56f8579e17c4dba836ec797 (diff) |
Migrate CI::Project to Project
Diffstat (limited to 'spec/lib/gitlab/backend')
-rw-r--r-- | spec/lib/gitlab/backend/grack_auth_spec.rb | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/spec/lib/gitlab/backend/grack_auth_spec.rb b/spec/lib/gitlab/backend/grack_auth_spec.rb index 73458735ad9..2dd27464de7 100644 --- a/spec/lib/gitlab/backend/grack_auth_spec.rb +++ b/spec/lib/gitlab/backend/grack_auth_spec.rb @@ -191,15 +191,10 @@ describe Grack::Auth, lib: true do context "when a gitlab ci token is provided" do let(:token) { "123" } - let(:gitlab_ci_project) { FactoryGirl.create :ci_project, token: token } + let(:project) { FactoryGirl.create :empty_project, token: token } before do - project.gitlab_ci_project = gitlab_ci_project - project.save - - gitlab_ci_service = project.build_gitlab_ci_service - gitlab_ci_service.active = true - gitlab_ci_service.save + project.update_attributes(token: token, builds_enabled: true) env["HTTP_AUTHORIZATION"] = ActionController::HttpAuthentication::Basic.encode_credentials("gitlab-ci-token", token) end |