Commit 589b28fd authored by Sean Arnold's avatar Sean Arnold Committed by Peter Leitzen

Add spec for SentryErrorType global id

Add changelog file
parent dbb4abc3
......@@ -14,7 +14,7 @@ class SentryErrorPresenter < Gitlab::View::Presenter::Delegated
end
def project_id
Gitlab::GlobalId.build(model_name: 'Project', id: error.project_id).to_s
Gitlab::GlobalId.build(model_name: 'SentryProject', id: error.project_id).to_s
end
def frequency
......
---
title: Fix type of SentryErrorType global ID
merge_request: 42185
author:
type: fixed
......@@ -26,4 +26,12 @@ RSpec.describe SentryErrorPresenter do
expect(count).to eq error.frequency.first[1]
end
end
describe '#project_id' do
subject { presenter.project_id }
it 'returns a global ID of the correct type' do
expect(subject).to eq(Gitlab::GlobalId.build(model_name: 'SentryProject', id: error.project_id).to_s)
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