diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-06-18 18:10:16 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-06-18 18:10:16 +0300 |
commit | c8cc2fe990c52cabcb9912b2b01b5bf16b33d88f (patch) | |
tree | 101b52764100d09d0f49e9277cfd7ac5383e7aeb /spec/workers/projects | |
parent | 38a1a6cb91bd4cd95d18db9a4bfd219bfb75401b (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/workers/projects')
-rw-r--r-- | spec/workers/projects/post_creation_worker_spec.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/workers/projects/post_creation_worker_spec.rb b/spec/workers/projects/post_creation_worker_spec.rb index 50c21575878..d1600daa3bd 100644 --- a/spec/workers/projects/post_creation_worker_spec.rb +++ b/spec/workers/projects/post_creation_worker_spec.rb @@ -36,7 +36,7 @@ RSpec.describe Projects::PostCreationWorker do create(:clusters_integrations_prometheus, cluster: cluster) end - it 'creates PrometheusService record', :aggregate_failures do + it 'creates an Integrations::Prometheus record', :aggregate_failures do subject service = project.prometheus_service @@ -53,7 +53,7 @@ RSpec.describe Projects::PostCreationWorker do create(:clusters_integrations_prometheus, cluster: cluster) end - it 'creates PrometheusService record', :aggregate_failures do + it 'creates an Integrations::Prometheus record', :aggregate_failures do subject service = project.prometheus_service @@ -64,7 +64,7 @@ RSpec.describe Projects::PostCreationWorker do it 'cleans invalid record and logs warning', :aggregate_failures do invalid_service_record = build(:prometheus_service, properties: { api_url: nil, manual_configuration: true }.to_json) - allow(PrometheusService).to receive(:new).and_return(invalid_service_record) + allow(::Integrations::Prometheus).to receive(:new).and_return(invalid_service_record) expect(Gitlab::ErrorTracking).to receive(:track_exception).with(an_instance_of(ActiveRecord::RecordInvalid), include(extra: { project_id: a_kind_of(Integer) })).twice subject @@ -74,7 +74,7 @@ RSpec.describe Projects::PostCreationWorker do end context 'shared Prometheus application is not available' do - it 'does not persist PrometheusService record', :aggregate_failures do + it 'does not persist an Integrations::Prometheus record' do subject expect(project.prometheus_service).to be_nil |