diff options
Diffstat (limited to 'spec/frontend/vue_shared/components/user_avatar/user_avatar_link_spec.js')
-rw-r--r-- | spec/frontend/vue_shared/components/user_avatar/user_avatar_link_spec.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/spec/frontend/vue_shared/components/user_avatar/user_avatar_link_spec.js b/spec/frontend/vue_shared/components/user_avatar/user_avatar_link_spec.js index 90f9156af38..443d4e32580 100644 --- a/spec/frontend/vue_shared/components/user_avatar/user_avatar_link_spec.js +++ b/spec/frontend/vue_shared/components/user_avatar/user_avatar_link_spec.js @@ -95,4 +95,18 @@ describe('User Avatar Link Component', () => { expect(wrapper.html()).toContain(badge); }); }); + + describe('when popover props provided', () => { + beforeEach(() => { + createWrapper({ popoverUserId: 1, popoverUsername: defaultProps.username }); + }); + + it('should render GlAvatarLink with popover support', () => { + expect(wrapper.attributes()).toMatchObject({ + href: defaultProps.linkHref, + 'data-user-id': '1', + 'data-username': `${defaultProps.username}`, + }); + }); + }); }); |