diff options
author | Ash McKenzie <amckenzie@gitlab.com> | 2018-06-05 14:42:18 +0300 |
---|---|---|
committer | Ash McKenzie <amckenzie@gitlab.com> | 2018-06-06 01:18:40 +0300 |
commit | bbafb85395cf2786f21a5a92745b9b3a181a4ce8 (patch) | |
tree | 38e135efa18036a6b76000e2d055241d60c66234 /spec/factories/merge_requests.rb | |
parent | a34666e655347f66fab578a134b568e997b7902e (diff) |
Add missing tests around rendering invalid merge requests (HTML+JSON)
Diffstat (limited to 'spec/factories/merge_requests.rb')
-rw-r--r-- | spec/factories/merge_requests.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/factories/merge_requests.rb b/spec/factories/merge_requests.rb index fab0ec22450..3441ce1b8cb 100644 --- a/spec/factories/merge_requests.rb +++ b/spec/factories/merge_requests.rb @@ -54,6 +54,11 @@ FactoryBot.define do state :opened end + trait :invalid do + source_branch "feature_one" + target_branch "feature_two" + end + trait :locked do state :locked end @@ -98,6 +103,7 @@ FactoryBot.define do factory :merged_merge_request, traits: [:merged] factory :closed_merge_request, traits: [:closed] factory :reopened_merge_request, traits: [:opened] + factory :invalid_merge_request, traits: [:invalid] factory :merge_request_with_diffs, traits: [:with_diffs] factory :merge_request_with_diff_notes do after(:create) do |mr| |