diff options
author | Rémy Coutable <remy@rymai.me> | 2017-01-26 09:01:42 +0000 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2017-01-26 09:01:42 +0000 |
commit | 0d3380ab5e3bf3b34a4e5a9089ab05957b911175 (patch) | |
tree | 122c1bc6b70880852606f26c1114eba29756bb86 /spec/controllers/projects/notes_controller_spec.rb | |
parent | 6d2fa87dd0b521c99ea885091714f7f11a238898 (diff) | |
parent | 4642ca6686d30e1bb203ece4836a294c868a6250 (diff) | |
download | gitlab-ce-0d3380ab5e3bf3b34a4e5a9089ab05957b911175.tar.gz |
Merge branch 'rs-empty_project-controllers' into 'master'
Use `:empty_project` where possible in controller specs
See merge request !8797
Diffstat (limited to 'spec/controllers/projects/notes_controller_spec.rb')
-rw-r--r-- | spec/controllers/projects/notes_controller_spec.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/spec/controllers/projects/notes_controller_spec.rb b/spec/controllers/projects/notes_controller_spec.rb index 9f6d4ec6537..dc597202050 100644 --- a/spec/controllers/projects/notes_controller_spec.rb +++ b/spec/controllers/projects/notes_controller_spec.rb @@ -2,7 +2,7 @@ require 'spec_helper' describe Projects::NotesController do let(:user) { create(:user) } - let(:project) { create(:project) } + let(:project) { create(:empty_project) } let(:issue) { create(:issue, project: project) } let(:note) { create(:note, noteable: issue, project: project) } @@ -16,6 +16,7 @@ describe Projects::NotesController do describe 'POST create' do let(:merge_request) { create(:merge_request) } + let(:project) { merge_request.source_project } let(:request_params) do { note: { note: 'some note', noteable_id: merge_request.id, noteable_type: 'MergeRequest' }, @@ -88,6 +89,7 @@ describe Projects::NotesController do end describe "resolving and unresolving" do + let(:project) { create(:project, :repository) } let(:merge_request) { create(:merge_request, source_project: project) } let(:note) { create(:diff_note_on_merge_request, noteable: merge_request, project: project) } |