Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-07-29 12:09:58 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-07-29 12:09:58 +0300
commit6c4a39fa9f77d6d7dd971118b5402a5387eb8846 (patch)
tree41065fdc4d56111b9359a061dac2181aad8adcd8 /spec/frontend
parenta412f4f58679c9d9120da6dc69ff02a6fcec0c5a (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/frontend')
-rw-r--r--spec/frontend/super_sidebar/components/user_name_group_spec.js16
1 files changed, 16 insertions, 0 deletions
diff --git a/spec/frontend/super_sidebar/components/user_name_group_spec.js b/spec/frontend/super_sidebar/components/user_name_group_spec.js
index bd02f3c17e3..a31ad93d143 100644
--- a/spec/frontend/super_sidebar/components/user_name_group_spec.js
+++ b/spec/frontend/super_sidebar/components/user_name_group_spec.js
@@ -97,6 +97,22 @@ describe('UserNameGroup component', () => {
it("sets the tooltip's target to the status container", () => {
expect(findGlTooltip().props('target')?.()).toBe(findUserStatus().element);
});
+
+ describe('Tooltip', () => {
+ it('renders the tooltip when message has some text', () => {
+ createWrapper({
+ status: { ...userMenuMockStatus, customized: true, message_html: 'Has text' },
+ });
+ expect(findGlTooltip().exists()).toBe(true);
+ });
+
+ it('does not render the tooltip when message is empty', () => {
+ createWrapper({
+ status: { ...userMenuMockStatus, customized: true, message_html: '' },
+ });
+ expect(findGlTooltip().exists()).toBe(false);
+ });
+ });
});
});