Commit 18a1d0a5 authored by Kamil Trzciński's avatar Kamil Trzciński

Merge branch 'chatops-output' into 'master'

Don't send schedule confirmations for chat jobs

See merge request gitlab-org/gitlab-ee!5312
parents 2aa998b4 63b7d8f3
---
title: Don't send schedule confirmations for chat jobs
merge_request:
author:
type: changed
......@@ -47,9 +47,10 @@ module Gitlab
# Returns the output to send back after a command has been scheduled.
def scheduled_output
{
text: message_text("<#{build_url}|The command has been scheduled!>")
}
# We return an empty message so that Slack still shows the input
# command, without polluting the channel with standard "The job has
# been scheduled" (or similar) responses.
{ text: '' }
end
private
......
......@@ -69,7 +69,7 @@ describe Gitlab::Chat::Responder::Slack do
it 'returns the output for a scheduled build' do
output = responder.scheduled_output
expect(output[:text]).to match(/<@U123>:.+The command has been scheduled!/)
expect(output).to eq({ text: '' })
end
end
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