diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-01-19 15:17:41 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-01-19 15:17:41 +0300 |
commit | e67f3f55d2b887e13181a37e34275a82fce28b9a (patch) | |
tree | b5e6fb003a03eaeb537e8fccf11af654d5dbd1c9 /spec/helpers/nav | |
parent | a87e8cad90b7d6d602cb5701d1dc588587684597 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/helpers/nav')
-rw-r--r-- | spec/helpers/nav/top_nav_helper_spec.rb | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/spec/helpers/nav/top_nav_helper_spec.rb b/spec/helpers/nav/top_nav_helper_spec.rb index 10bd45e3189..ef6a6827826 100644 --- a/spec/helpers/nav/top_nav_helper_spec.rb +++ b/spec/helpers/nav/top_nav_helper_spec.rb @@ -20,7 +20,6 @@ RSpec.describe Nav::TopNavHelper do let(:current_group) { nil } let(:with_current_settings_admin_mode) { false } let(:with_header_link_admin_mode) { false } - let(:with_sherlock_enabled) { false } let(:with_projects) { false } let(:with_groups) { false } let(:with_milestones) { false } @@ -34,7 +33,6 @@ RSpec.describe Nav::TopNavHelper do before do allow(Gitlab::CurrentSettings).to receive(:admin_mode) { with_current_settings_admin_mode } allow(helper).to receive(:header_link?).with(:admin_mode) { with_header_link_admin_mode } - allow(Gitlab::Sherlock).to receive(:enabled?) { with_sherlock_enabled } # Defaulting all `dashboard_nav_link?` calls to false ensures the EE-specific behavior # is not enabled in this CE spec @@ -434,27 +432,6 @@ RSpec.describe Nav::TopNavHelper do expect(subject[:shortcuts]).to eq([expected_shortcuts]) end end - - context 'when sherlock is enabled' do - let(:with_sherlock_enabled) { true } - - before do - # Note: We have to mock the sherlock route because the route is conditional on - # sherlock being enabled, but it parsed at Rails load time and can't be overridden - # in a spec. - allow(helper).to receive(:sherlock_transactions_path) { '/fake_sherlock_path' } - end - - it 'has sherlock as last :secondary item' do - expected_sherlock_item = ::Gitlab::Nav::TopNavMenuItem.build( - id: 'sherlock', - title: 'Sherlock Transactions', - icon: 'admin', - href: '/fake_sherlock_path' - ) - expect(subject[:secondary].last).to eq(expected_sherlock_item) - end - end end context 'when current_user is admin' do |