Commit 67d3ca5d authored by Patrick Bajao's avatar Patrick Bajao

Merge branch...

Merge branch '232957-include-merge-request-description-or-any-custom-merge-commit-message-not-working-with-merge' into 'master'

Resolve ""Include merge request description" or any custom merge commit message not working with Merge Trains enabled"

See merge request gitlab-org/gitlab!57787
parents fba06b96 b91b4b35
---
title: Fix issue where merge description not showing when merged with merge train
merge_request: 57787
author:
type: fixed
......@@ -62,7 +62,7 @@ module MergeTrains
def merge!
merge_train.start_merge!
MergeRequests::MergeService.new(project, merge_user, merge_request.merge_params)
MergeRequests::MergeService.new(project, merge_user, merge_request.merge_params.with_indifferent_access)
.execute(merge_request, skip_discussions_check: true)
raise ProcessError, "failed to merge. #{merge_request.merge_error}" unless merge_request.merged?
......
......@@ -208,7 +208,7 @@ RSpec.describe MergeTrains::RefreshMergeRequestService do
expect(merge_request).to receive(:cleanup_refs).with(only: :train)
expect(merge_request.merge_train).to receive(:start_merge!).and_call_original
expect(merge_request.merge_train).to receive(:finish_merge!).and_call_original
expect_next_instance_of(MergeRequests::MergeService, project, maintainer, anything) do |service|
expect_next_instance_of(MergeRequests::MergeService, project, maintainer, instance_of(HashWithIndifferentAccess)) do |service|
expect(service).to receive(:execute).with(merge_request, skip_discussions_check: true).and_call_original
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment