diff options
Diffstat (limited to 'spec/lib/sidebars/projects/super_sidebar_menus/secure_menu_spec.rb')
-rw-r--r-- | spec/lib/sidebars/projects/super_sidebar_menus/secure_menu_spec.rb | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/spec/lib/sidebars/projects/super_sidebar_menus/secure_menu_spec.rb b/spec/lib/sidebars/projects/super_sidebar_menus/secure_menu_spec.rb new file mode 100644 index 00000000000..74ef761332e --- /dev/null +++ b/spec/lib/sidebars/projects/super_sidebar_menus/secure_menu_spec.rb @@ -0,0 +1,29 @@ +# frozen_string_literal: true + +require 'spec_helper' + +RSpec.describe Sidebars::Projects::SuperSidebarMenus::SecureMenu, feature_category: :navigation do + subject { described_class.new({}) } + + let(:items) { subject.instance_variable_get(:@items) } + + it 'has title and sprite_icon' do + expect(subject.title).to eq(s_("Navigation|Secure")) + expect(subject.sprite_icon).to eq("shield") + end + + it 'defines list of NilMenuItem placeholders' do + expect(items.map(&:class).uniq).to eq([Sidebars::NilMenuItem]) + expect(items.map(&:item_id)).to eq([ + :discover_project_security, + :dashboard, + :vulnerability_report, + :dependency_list, + :license_compliance, + :audit_events, + :scan_policies, + :on_demand_scans, + :configuration + ]) + end +end |