Commit cbd56e77 authored by Phil Hughes's avatar Phil Hughes

Merge branch '335877-slack-application-remove-button-redirects-to-404' into 'master'

Fix "Remove" button in Slack app integration

See merge request gitlab-org/gitlab!66506
parents 5a217e05 23e700d5
...@@ -87,6 +87,7 @@ export default { ...@@ -87,6 +87,7 @@ export default {
}, },
helpHtmlConfig: { helpHtmlConfig: {
ADD_TAGS: ['use'], // to support icon SVGs ADD_TAGS: ['use'], // to support icon SVGs
FORBID_ATTR: [], // This is trusted input so we can override the default config to allow data-* attributes
}, },
}; };
</script> </script>
......
...@@ -278,6 +278,7 @@ describe('IntegrationForm', () => { ...@@ -278,6 +278,7 @@ describe('IntegrationForm', () => {
<svg class="gl-icon"> <svg class="gl-icon">
<use></use> <use></use>
</svg> </svg>
<a data-confirm="Are you sure?" data-method="delete" href="/settings/slack"></a>
</div> </div>
`); `);
...@@ -291,9 +292,14 @@ describe('IntegrationForm', () => { ...@@ -291,9 +292,14 @@ describe('IntegrationForm', () => {
}); });
const helpHtml = wrapper.findByTestId(mockTestId); const helpHtml = wrapper.findByTestId(mockTestId);
const helpLink = helpHtml.find('a');
expect(helpHtml.isVisible()).toBe(true); expect(helpHtml.isVisible()).toBe(true);
expect(helpHtml.find('svg').isVisible()).toBe(true); expect(helpHtml.find('svg').isVisible()).toBe(true);
expect(helpLink.attributes()).toMatchObject({
'data-confirm': 'Are you sure?',
'data-method': 'delete',
});
}); });
}); });
}); });
......
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