diff options
Diffstat (limited to 'spec/features/projects/integrations')
-rw-r--r-- | spec/features/projects/integrations/prometheus_external_alerts_spec.rb | 34 | ||||
-rw-r--r-- | spec/features/projects/integrations/user_activates_prometheus_spec.rb | 5 |
2 files changed, 2 insertions, 37 deletions
diff --git a/spec/features/projects/integrations/prometheus_external_alerts_spec.rb b/spec/features/projects/integrations/prometheus_external_alerts_spec.rb deleted file mode 100644 index 7e56ca13e23..00000000000 --- a/spec/features/projects/integrations/prometheus_external_alerts_spec.rb +++ /dev/null @@ -1,34 +0,0 @@ -# frozen_string_literal: true - -require 'spec_helper' - -RSpec.describe 'Prometheus external alerts', :js do - include_context 'project integration activation' - - let(:alerts_section_selector) { '.js-prometheus-alerts' } - let(:alerts_section) { page.find(alerts_section_selector) } - - context 'with manual configuration' do - before do - create(:prometheus_integration, project: project, api_url: 'http://prometheus.example.com', manual_configuration: '1', active: true) - end - - it 'shows the Alerts section' do - visit_project_integration('Prometheus') - - expect(alerts_section).to have_content('Alerts') - expect(alerts_section).to have_content('Receive alerts from manually configured Prometheus servers.') - expect(alerts_section).to have_content('URL') - expect(alerts_section).to have_content('Authorization key') - end - end - - context 'with no configuration' do - it 'does not show the Alerts section' do - visit_project_integration('Prometheus') - wait_for_requests - - expect(page).not_to have_css(alerts_section_selector) - end - end -end diff --git a/spec/features/projects/integrations/user_activates_prometheus_spec.rb b/spec/features/projects/integrations/user_activates_prometheus_spec.rb index 80629af6fce..56b895919b8 100644 --- a/spec/features/projects/integrations/user_activates_prometheus_spec.rb +++ b/spec/features/projects/integrations/user_activates_prometheus_spec.rb @@ -9,14 +9,13 @@ RSpec.describe 'User activates Prometheus' do stub_request(:get, /.*prometheus.example.com.*/) end - it 'does not activate integration and informs about deprecation', :js do + it 'saves and activates integration', :js do visit_project_integration('Prometheus') check('Active') fill_in('API URL', with: 'http://prometheus.example.com') click_button('Save changes') - expect(page).not_to have_content('Prometheus settings saved and active.') - expect(page).to have_content('Fields on this page have been deprecated.') + expect(page).to have_content('Prometheus settings saved and active.') end end |