Commit 10f5cfe3 authored by rpereira2's avatar rpereira2 Committed by Peter Leitzen

Fix failing operations/update_service_spec

- Fix specs failing due to new validation.
- Also remove a method definition that was repeated.
parent 258c3d2f
...@@ -27,15 +27,6 @@ module Sentry ...@@ -27,15 +27,6 @@ module Sentry
} }
end end
def request_params
{
headers: {
'Authorization' => "Bearer #{@token}"
},
follow_redirects: false
}
end
def get_issues(issue_status:, limit:) def get_issues(issue_status:, limit:)
resp = Gitlab::HTTP.get( resp = Gitlab::HTTP.get(
issues_api_url, issues_api_url,
......
...@@ -17,7 +17,7 @@ describe Projects::Operations::UpdateService do ...@@ -17,7 +17,7 @@ describe Projects::Operations::UpdateService do
{ {
error_tracking_setting_attributes: { error_tracking_setting_attributes: {
enabled: false, enabled: false,
api_url: 'http://url', api_url: 'http://gitlab.com/api/0/projects/org/project',
token: 'token' token: 'token'
} }
} }
...@@ -32,7 +32,7 @@ describe Projects::Operations::UpdateService do ...@@ -32,7 +32,7 @@ describe Projects::Operations::UpdateService do
project.reload project.reload
expect(project.error_tracking_setting).not_to be_enabled expect(project.error_tracking_setting).not_to be_enabled
expect(project.error_tracking_setting.api_url).to eq('http://url') expect(project.error_tracking_setting.api_url).to eq('http://gitlab.com/api/0/projects/org/project')
expect(project.error_tracking_setting.token).to eq('token') expect(project.error_tracking_setting.token).to eq('token')
end end
end end
...@@ -42,7 +42,7 @@ describe Projects::Operations::UpdateService do ...@@ -42,7 +42,7 @@ describe Projects::Operations::UpdateService do
{ {
error_tracking_setting_attributes: { error_tracking_setting_attributes: {
enabled: true, enabled: true,
api_url: 'http://url', api_url: 'http://gitlab.com/api/0/projects/org/project',
token: 'token' token: 'token'
} }
} }
...@@ -52,7 +52,7 @@ describe Projects::Operations::UpdateService do ...@@ -52,7 +52,7 @@ describe Projects::Operations::UpdateService do
expect(result[:status]).to eq(:success) expect(result[:status]).to eq(:success)
expect(project.error_tracking_setting).to be_enabled expect(project.error_tracking_setting).to be_enabled
expect(project.error_tracking_setting.api_url).to eq('http://url') expect(project.error_tracking_setting.api_url).to eq('http://gitlab.com/api/0/projects/org/project')
expect(project.error_tracking_setting.token).to eq('token') expect(project.error_tracking_setting.token).to eq('token')
end end
end end
......
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