summaryrefslogtreecommitdiff
path: root/spec/frontend/vue_shared/components/user_popover/user_popover_spec.js
diff options
context:
space:
mode:
Diffstat (limited to 'spec/frontend/vue_shared/components/user_popover/user_popover_spec.js')
-rw-r--r--spec/frontend/vue_shared/components/user_popover/user_popover_spec.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/frontend/vue_shared/components/user_popover/user_popover_spec.js b/spec/frontend/vue_shared/components/user_popover/user_popover_spec.js
index 09633daf587..3329199a46b 100644
--- a/spec/frontend/vue_shared/components/user_popover/user_popover_spec.js
+++ b/spec/frontend/vue_shared/components/user_popover/user_popover_spec.js
@@ -271,6 +271,12 @@ describe('User Popover Component', () => {
expect(securityBotDocsLink.text()).toBe('Learn more about GitLab Security Bot');
});
+ it("does not show a link to the bot's documentation if there is no website_url", () => {
+ createWrapper({ user: { ...SECURITY_BOT_USER, websiteUrl: null } });
+ const securityBotDocsLink = findSecurityBotDocsLink();
+ expect(securityBotDocsLink.exists()).toBe(false);
+ });
+
it("doesn't escape user's name", () => {
createWrapper({ user: { ...SECURITY_BOT_USER, name: '%<>\';"' } });
const securityBotDocsLink = findSecurityBotDocsLink();