Commit 43bcfcdc authored by David O'Regan's avatar David O'Regan Committed by Natalia Tepluhina

Remove designs from incidents

parent 95a1e91c
- return if @issue.incident?
- requirements_link_url = help_page_path('user/project/issues/design_management', anchor: 'requirements') - requirements_link_url = help_page_path('user/project/issues/design_management', anchor: 'requirements')
- requirements_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: requirements_link_url } - requirements_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: requirements_link_url }
- link_end = '</a>'.html_safe - link_end = '</a>'.html_safe
......
---
title: Remove designs from incidents
merge_request: 41757
author:
type: changed
...@@ -20,6 +20,19 @@ RSpec.describe 'Issue Detail', :js do ...@@ -20,6 +20,19 @@ RSpec.describe 'Issue Detail', :js do
end end
end end
context 'when user displays the issue as an incident' do
let(:issue) { create(:incident, project: project, author: user) }
before do
visit project_issue_path(project, issue)
wait_for_requests
end
it 'does not show design management' do
expect(page).not_to have_selector('.js-design-management')
end
end
context 'when issue description has xss snippet' do context 'when issue description has xss snippet' do
before do before do
issue.update!(description: '![xss" onload=alert(1);//](a)') issue.update!(description: '![xss" onload=alert(1);//](a)')
......
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