Commit e013cd44e0da544cd23e0cdb1eed44b2f8cdf494
1 parent
4cde3593
Exists in
spb-stable
and in
3 other branches
Fix mr specs
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Showing
1 changed file
with
3 additions
and
4 deletions
Show diff stats
spec/models/merge_request_spec.rb
@@ -73,14 +73,13 @@ describe MergeRequest do | @@ -73,14 +73,13 @@ describe MergeRequest do | ||
73 | 73 | ||
74 | describe '#for_fork?' do | 74 | describe '#for_fork?' do |
75 | it 'returns true if the merge request is for a fork' do | 75 | it 'returns true if the merge request is for a fork' do |
76 | - subject.source_project = create(:source_project) | ||
77 | - subject.target_project = create(:target_project) | 76 | + subject.source_project = create(:project, namespace: create(:group)) |
77 | + subject.target_project = create(:project, namespace: create(:group)) | ||
78 | 78 | ||
79 | subject.for_fork?.should be_true | 79 | subject.for_fork?.should be_true |
80 | end | 80 | end |
81 | + | ||
81 | it 'returns false if is not for a fork' do | 82 | it 'returns false if is not for a fork' do |
82 | - subject.source_project = create(:source_project) | ||
83 | - subject.target_project = subject.source_project | ||
84 | subject.for_fork?.should be_false | 83 | subject.for_fork?.should be_false |
85 | end | 84 | end |
86 | end | 85 | end |