Commit 822d61ae authored by Rajendra Kadam's avatar Rajendra Kadam Committed by Peter Leitzen

Remove constant usage from clone dashboard service spec

parent b94dac6a
......@@ -399,7 +399,6 @@ RSpec/LeakyConstantDeclaration:
- 'spec/services/clusters/applications/check_upgrade_progress_service_spec.rb'
- 'spec/services/clusters/applications/ingress_modsecurity_usage_service_spec.rb'
- 'spec/services/issues/resolve_discussions_spec.rb'
- 'spec/services/metrics/dashboard/clone_dashboard_service_spec.rb'
- 'spec/support/shared_contexts/spam_constants.rb'
- 'spec/support/shared_examples/quick_actions/issuable/issuable_quick_actions_shared_examples.rb'
- 'spec/support_specs/matchers/exceed_query_limit_helpers_spec.rb'
......
---
title: Fix leaky constant cop issue in clone dashboard service spec
merge_request: 31962
author: Rajendra Kadam
type: fixed
......@@ -5,8 +5,6 @@ require 'spec_helper'
describe Metrics::Dashboard::CloneDashboardService, :use_clean_rails_memory_store_caching do
include MetricsDashboardHelpers
STAGES = ::Gitlab::Metrics::Dashboard::Stages
let_it_be(:user) { create(:user) }
let_it_be(:project) { create(:project, :repository) }
let_it_be(:environment) { create(:environment, project: project) }
......@@ -83,7 +81,7 @@ describe Metrics::Dashboard::CloneDashboardService, :use_clean_rails_memory_stor
allow(::Gitlab::Metrics::Dashboard::Processor).to receive(:new).and_return(double(process: file_content_hash))
end
it_behaves_like 'valid dashboard cloning process', ::Metrics::Dashboard::SystemDashboardService::DASHBOARD_PATH, [STAGES::CommonMetricsInserter, STAGES::CustomMetricsInserter, STAGES::Sorter]
it_behaves_like 'valid dashboard cloning process', ::Metrics::Dashboard::SystemDashboardService::DASHBOARD_PATH, [::Gitlab::Metrics::Dashboard::Stages::CommonMetricsInserter, ::Gitlab::Metrics::Dashboard::Stages::CustomMetricsInserter, ::Gitlab::Metrics::Dashboard::Stages::Sorter]
context 'selected branch already exists' do
let(:branch) { 'existing_branch' }
......
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