diff options
author | Tim Zallmann <tzallmann@gitlab.com> | 2017-06-08 00:37:45 +0200 |
---|---|---|
committer | Tim Zallmann <tzallmann@gitlab.com> | 2017-06-08 00:37:45 +0200 |
commit | 39d976cf5881c947eefeb45a2f8fe2922923eac6 (patch) | |
tree | 29cc255d75683cb54bc20c518ec2505b5d2183ab /spec/features/explore | |
parent | 81b565ee36179561dcae8d428a712fa5fe1cc04b (diff) | |
download | gitlab-ce-39d976cf5881c947eefeb45a2f8fe2922923eac6.tar.gz |
Added more negative checks for public project23603-add-extra-functionality-for-the-top-right-plus-button
Diffstat (limited to 'spec/features/explore')
-rw-r--r-- | spec/features/explore/new_menu_spec.rb | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/spec/features/explore/new_menu_spec.rb b/spec/features/explore/new_menu_spec.rb index cbd97ff74b3..15a6354211b 100644 --- a/spec/features/explore/new_menu_spec.rb +++ b/spec/features/explore/new_menu_spec.rb @@ -4,8 +4,8 @@ feature 'Top Plus Menu', feature: true, js: true do let(:user) { create :user } let(:guest_user) { create :user} let(:group) { create(:group) } - let(:public_group) { create(:group, :public) } let(:project) { create(:project, :repository, creator: user, namespace: user.namespace) } + let(:public_project) { create(:project, :public) } before do group.add_owner(user) @@ -127,6 +127,24 @@ feature 'Top Plus Menu', feature: true, js: true do expect(find('.header-new.dropdown')).not_to have_selector('.header-new-project-snippet') end + scenario 'public project has no New Issue Button' do + visit namespace_project_path(public_project.namespace, public_project) + + hasnot_topmenuitem("New issue") + end + + scenario 'public project has no New merge request menu item' do + visit namespace_project_path(public_project.namespace, public_project) + + hasnot_topmenuitem("New merge request") + end + + scenario 'public project has no New project snippet menu item' do + visit namespace_project_path(public_project.namespace, public_project) + + expect(find('.header-new.dropdown')).not_to have_selector('.header-new-project-snippet') + end + scenario 'has no New subgroup menu item' do visit group_path(group) |