summaryrefslogtreecommitdiff
path: root/spec/factories/merge_requests.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/factories/merge_requests.rb')
-rw-r--r--spec/factories/merge_requests.rb24
1 files changed, 24 insertions, 0 deletions
diff --git a/spec/factories/merge_requests.rb b/spec/factories/merge_requests.rb
index abccd775c8a..b10c04a37f7 100644
--- a/spec/factories/merge_requests.rb
+++ b/spec/factories/merge_requests.rb
@@ -121,6 +121,18 @@ FactoryBot.define do
end
end
+ trait :with_accessibility_reports do
+ after(:build) do |merge_request|
+ merge_request.head_pipeline = build(
+ :ci_pipeline,
+ :success,
+ :with_accessibility_reports,
+ project: merge_request.source_project,
+ ref: merge_request.source_branch,
+ sha: merge_request.diff_head_sha)
+ end
+ end
+
trait :with_coverage_reports do
after(:build) do |merge_request|
merge_request.head_pipeline = build(
@@ -133,6 +145,18 @@ FactoryBot.define do
end
end
+ trait :with_terraform_reports do
+ after(:build) do |merge_request|
+ merge_request.head_pipeline = build(
+ :ci_pipeline,
+ :success,
+ :with_terraform_reports,
+ project: merge_request.source_project,
+ ref: merge_request.source_branch,
+ sha: merge_request.diff_head_sha)
+ end
+ end
+
trait :with_exposed_artifacts do
after(:build) do |merge_request|
merge_request.head_pipeline = build(