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>2020-03-24 15:09:42 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-03-24 15:09:42 +0300
commit729e3765d5feb762df1ccfbc228a8dd4662aa3f9 (patch)
treef326420fc64999c6bcc28816ed54f0972fb46459 /spec/helpers
parent6f7881ee9dcec34141a8f34fc814b56b366d2b48 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/helpers')
-rw-r--r--spec/helpers/nav_helper_spec.rb20
1 files changed, 20 insertions, 0 deletions
diff --git a/spec/helpers/nav_helper_spec.rb b/spec/helpers/nav_helper_spec.rb
index f92dca11136..6bdbec1203c 100644
--- a/spec/helpers/nav_helper_spec.rb
+++ b/spec/helpers/nav_helper_spec.rb
@@ -117,4 +117,24 @@ describe NavHelper, :do_not_mock_admin_mode do
it { is_expected.to all(be_a(String)) }
end
+
+ describe '.show_user_notification_dot?' do
+ subject { helper.show_user_notification_dot? }
+
+ context 'when experiment is disabled' do
+ before do
+ allow(helper).to receive(:experiment_enabled?).with(:ci_notification_dot).and_return(false)
+ end
+
+ it { is_expected.to be_falsey }
+ end
+
+ context 'when experiment is enabled' do
+ before do
+ allow(helper).to receive(:experiment_enabled?).with(:ci_notification_dot).and_return(true)
+ end
+
+ it { is_expected.to be_truthy }
+ end
+ end
end