From 7351a484d79236b7e9d47c86f2fcc970b7ae10b0 Mon Sep 17 00:00:00 2001 From: GitLab Bot Date: Mon, 10 Feb 2020 12:08:59 +0000 Subject: Add latest changes from gitlab-org/gitlab@master --- spec/lib/gitlab/ci/pipeline/seed/deployment_spec.rb | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'spec/lib/gitlab/ci') diff --git a/spec/lib/gitlab/ci/pipeline/seed/deployment_spec.rb b/spec/lib/gitlab/ci/pipeline/seed/deployment_spec.rb index 90f4b06cea0..c5c91135f60 100644 --- a/spec/lib/gitlab/ci/pipeline/seed/deployment_spec.rb +++ b/spec/lib/gitlab/ci/pipeline/seed/deployment_spec.rb @@ -33,13 +33,18 @@ describe Gitlab::Ci::Pipeline::Seed::Deployment do expect(subject.iid).to be_present expect(subject.environment.name).to eq('production') expect(subject.cluster).to be_nil + expect(subject.deployment_cluster).to be_nil end context 'when environment has deployment platform' do let!(:cluster) { create(:cluster, :provided_by_gcp, projects: [project]) } - it 'returns a deployment with cluster id' do - expect(subject.cluster).to eq(cluster) + it 'sets the cluster and deployment_cluster' do + expect(subject.cluster).to eq(cluster) # until we stop double writing in 12.9: https://gitlab.com/gitlab-org/gitlab/issues/202628 + expect(subject.deployment_cluster).to have_attributes( + cluster_id: cluster.id, + kubernetes_namespace: subject.environment.deployment_namespace + ) end end -- cgit v1.2.3