diff options
author | Thong Kuah <tkuah@gitlab.com> | 2019-07-25 07:31:53 +0300 |
---|---|---|
committer | Thong Kuah <tkuah@gitlab.com> | 2019-07-25 07:46:20 +0300 |
commit | 41f87e9e99e14f7d591f222b0246467acd040625 (patch) | |
tree | 3c890316bb7a0f8755831ecfb8d94d2282c900ef /spec/models/deployment_metrics_spec.rb | |
parent | 7fa0c7662b88efa72d29087a273f0b6c1e484b3e (diff) |
Removes potentially incorrect, and slow fallback
Deployment_platform is relatively expensive and calling this after the
fact means that this may not be the cluster that was deployed to.
Correspondingly reduce the leeway given in the related N+1 spec
Diffstat (limited to 'spec/models/deployment_metrics_spec.rb')
-rw-r--r-- | spec/models/deployment_metrics_spec.rb | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/spec/models/deployment_metrics_spec.rb b/spec/models/deployment_metrics_spec.rb index 0aadb1f3a5e..7c574a8b6c8 100644 --- a/spec/models/deployment_metrics_spec.rb +++ b/spec/models/deployment_metrics_spec.rb @@ -49,18 +49,6 @@ describe DeploymentMetrics do it { is_expected.to be_truthy } end - - context 'fallback deployment platform' do - let(:cluster) { create(:cluster, :provided_by_user, environment_scope: '*', projects: [deployment.project]) } - let!(:prometheus) { create(:clusters_applications_prometheus, :installed, cluster: cluster) } - - before do - expect(deployment.project).to receive(:deployment_platform).and_return(cluster.platform) - expect(cluster.application_prometheus).to receive(:can_query?).and_return(true) - end - - it { is_expected.to be_truthy } - end end end |