Commit 64bb0d37 authored by Pawel Chojnacki's avatar Pawel Chojnacki

cleanup wip

parent b97d5b65
...@@ -42,6 +42,7 @@ describe Projects::DeploymentsController do ...@@ -42,6 +42,7 @@ describe Projects::DeploymentsController do
before do before do
allow(controller).to receive(:deployment).and_return(deployment) allow(controller).to receive(:deployment).and_return(deployment)
end end
context 'when metrics are disabled' do context 'when metrics are disabled' do
before do before do
allow(deployment).to receive(:has_metrics?).and_return false allow(deployment).to receive(:has_metrics?).and_return false
...@@ -114,6 +115,7 @@ describe Projects::DeploymentsController do ...@@ -114,6 +115,7 @@ describe Projects::DeploymentsController do
before do before do
allow(controller).to receive(:deployment).and_return(deployment) allow(controller).to receive(:deployment).and_return(deployment)
end end
context 'when metrics are disabled' do context 'when metrics are disabled' do
before do before do
allow(deployment).to receive(:has_metrics?).and_return false allow(deployment).to receive(:has_metrics?).and_return false
......
...@@ -338,7 +338,9 @@ describe Projects::EnvironmentsController do ...@@ -338,7 +338,9 @@ describe Projects::EnvironmentsController do
context 'when environment has some metrics' do context 'when environment has some metrics' do
before do before do
expect(environment).to receive(:additional_metrics).and_return({ expect(environment)
.to receive(:additional_metrics)
.and_return({
success: true, success: true,
data: {}, data: {},
last_update: 42 last_update: 42
......
...@@ -8,7 +8,6 @@ describe Projects::ServicesController, '(JavaScript fixtures)', type: :controlle ...@@ -8,7 +8,6 @@ describe Projects::ServicesController, '(JavaScript fixtures)', type: :controlle
let(:project) { create(:project_empty_repo, namespace: namespace, path: 'services-project') } let(:project) { create(:project_empty_repo, namespace: namespace, path: 'services-project') }
let!(:service) { create(:prometheus_service, project: project) } let!(:service) { create(:prometheus_service, project: project) }
render_views render_views
before(:all) do before(:all) do
......
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