Commit 65e906db authored by Achilleas Pipinellis's avatar Achilleas Pipinellis

Merge branch 'add-deployment-id-to-deployment-payload-332819' into 'master'

Add deployment_id to deployment payloads (#332819)

See merge request gitlab-org/gitlab!67577
parents 75bc912e def00fea
......@@ -1396,6 +1396,7 @@ X-Gitlab-Event: Deployment Hook
"object_kind": "deployment",
"status": "success",
"status_changed_at":"2021-04-28 21:50:00 +0200",
"deployment_id": 15,
"deployable_id": 796,
"deployable_url": "http://10.126.0.2:3000/root/test-deployment-webhooks/-/jobs/796",
"environment": "staging",
......
......@@ -16,6 +16,7 @@ module Gitlab
object_kind: 'deployment',
status: deployment.status,
status_changed_at: status_changed_at,
deployment_id: deployment.id,
deployable_id: deployment.deployable_id,
deployable_url: deployable_url,
environment: deployment.environment.name,
......
......@@ -27,6 +27,7 @@ RSpec.describe Gitlab::DataBuilder::Deployment do
expect(data[:status]).to eq('failed')
expect(data[:status_changed_at]).to eq(status_changed_at)
expect(data[:deployment_id]).to eq(deployment.id)
expect(data[:deployable_id]).to eq(deployable.id)
expect(data[:deployable_url]).to eq(expected_deployable_url)
expect(data[:environment]).to eq("somewhere")
......
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