debian-mirror-gitlab/spec/views/projects/settings/operations/show.html.haml_spec.rb
2019-02-13 22:33:31 +05:30

37 lines
962 B
Ruby

# frozen_string_literal: true
require 'spec_helper'
require 'rails_helper'
describe 'projects/settings/operations/show' do
let(:project) { create(:project) }
let(:user) { create(:user) }
before do
assign :project, project
end
describe 'Operations > Error Tracking' do
before do
project.add_reporter(user)
allow(view).to receive(:error_tracking_setting)
.and_return(error_tracking_setting)
allow(view).to receive(:current_user).and_return(user)
end
let!(:error_tracking_setting) do
create(:project_error_tracking_setting, project: project)
end
context 'Settings page ' do
it 'renders the Operations Settings page' do
render
expect(rendered).to have_content _('Error Tracking')
expect(rendered).to have_content _('To link Sentry to GitLab, enter your Sentry URL and Auth Token')
expect(rendered).to have_content _('Active')
end
end
end
end