summaryrefslogtreecommitdiff
path: root/spec/features/projects/features_visibility_spec.rb
diff options
context:
space:
mode:
authorPhil Hughes <me@iamphill.com>2016-10-21 12:14:14 +0100
committerPhil Hughes <me@iamphill.com>2016-11-01 08:35:23 +0000
commitb5decb21813e23d7a6828f6aa70bac909b6ce09f (patch)
tree9702b39fd6cd2ca35e9ec5a2412847cf277b6f11 /spec/features/projects/features_visibility_spec.rb
parentb328c7885532ccff70e1f9f7dc970a8dde0c52d6 (diff)
downloadgitlab-ce-b5decb21813e23d7a6828f6aa70bac909b6ce09f.tar.gz
Hide project activity tabs when features are disabled
Diffstat (limited to 'spec/features/projects/features_visibility_spec.rb')
-rw-r--r--spec/features/projects/features_visibility_spec.rb18
1 files changed, 18 insertions, 0 deletions
diff --git a/spec/features/projects/features_visibility_spec.rb b/spec/features/projects/features_visibility_spec.rb
index d25cf7fb353..e796ee570b7 100644
--- a/spec/features/projects/features_visibility_spec.rb
+++ b/spec/features/projects/features_visibility_spec.rb
@@ -164,5 +164,23 @@ describe 'Edit Project Settings', feature: true do
expect(page).to have_content "Customize your workflow!"
end
+
+ it "hides project activity tabs" do
+ select "Disabled", from: "project_project_feature_attributes_repository_access_level"
+ select "Disabled", from: "project_project_feature_attributes_issues_access_level"
+ select "Disabled", from: "project_project_feature_attributes_wiki_access_level"
+
+ click_button "Save changes"
+ wait_for_ajax
+
+ visit activity_namespace_project_path(project.namespace, project)
+
+ page.within(".event-filter") do
+ expect(page).to have_selector("a", count: 2)
+ expect(page).not_to have_content("Push events")
+ expect(page).not_to have_content("Merge events")
+ expect(page).not_to have_content("Comments")
+ end
+ end
end
end