text: "[myspace/myproject](#{project.web_url})\n[Job ##{ci_build.id}](#{job_url}), SHA [#{deployment.short_sha}](#{commit_url}), by John Smith (smith)",
text: "[myspace/myproject](#{project.web_url}) with job [##{ci_build.id}](#{job_url}) by [John Smith (smith)](#{user_url})\n[#{deployment.short_sha}](#{commit_url}): #{commit.title}",
color: "good"
color: "good"
}])
}])
end
end
...
@@ -120,7 +123,7 @@ describe ChatMessage::DeploymentMessage do
...
@@ -120,7 +123,7 @@ describe ChatMessage::DeploymentMessage do
message=described_class.new(data)
message=described_class.new(data)
expect(message.attachments).toeq([{
expect(message.attachments).toeq([{
text: "[project_path_with_namespace](project_web_url)\n[Job #3](deployable_url), SHA [12345678](commit_url), by Jane Person (jane)",
text: "[project_path_with_namespace](project_web_url) with job [#3](deployable_url) by [Jane Person (jane)](user_url)\n[12345678](commit_url): commit title text",
color: "danger"
color: "danger"
}])
}])
end
end
...
@@ -131,7 +134,7 @@ describe ChatMessage::DeploymentMessage do
...
@@ -131,7 +134,7 @@ describe ChatMessage::DeploymentMessage do
message=described_class.new(data)
message=described_class.new(data)
expect(message.attachments).toeq([{
expect(message.attachments).toeq([{
text: "[project_path_with_namespace](project_web_url)\n[Job #3](deployable_url), SHA [12345678](commit_url), by Jane Person (jane)",
text: "[project_path_with_namespace](project_web_url) with job [#3](deployable_url) by [Jane Person (jane)](user_url)\n[12345678](commit_url): commit title text",
color: "warning"
color: "warning"
}])
}])
end
end
...
@@ -142,7 +145,7 @@ describe ChatMessage::DeploymentMessage do
...
@@ -142,7 +145,7 @@ describe ChatMessage::DeploymentMessage do
message=described_class.new(data)
message=described_class.new(data)
expect(message.attachments).toeq([{
expect(message.attachments).toeq([{
text: "[project_path_with_namespace](project_web_url)\n[Job #3](deployable_url), SHA [12345678](commit_url), by Jane Person (jane)",
text: "[project_path_with_namespace](project_web_url) with job [#3](deployable_url) by [Jane Person (jane)](user_url)\n[12345678](commit_url): commit title text",