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>2022-08-17 00:12:07 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2022-08-17 00:12:07 +0300
commit2571f434015308eccb425059ad5e82851521265a (patch)
treea323b0a704a287e8e94d25e2480f321d13bab6cc /spec/policies
parent8a9790b0db723db32f8dff511ee032e5e8e3b583 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/policies')
-rw-r--r--spec/policies/issue_policy_spec.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/spec/policies/issue_policy_spec.rb b/spec/policies/issue_policy_spec.rb
index 2756f8b196d..7ca4baddb79 100644
--- a/spec/policies/issue_policy_spec.rb
+++ b/spec/policies/issue_policy_spec.rb
@@ -309,18 +309,23 @@ RSpec.describe IssuePolicy do
it 'forbids visitors from viewing issues' do
expect(permissions(visitor, issue)).to be_disallowed(:read_issue)
end
+
it 'forbids visitors from commenting' do
expect(permissions(visitor, issue)).to be_disallowed(:create_note)
end
+
it 'forbids visitors from subscribing' do
expect(permissions(visitor, issue)).to be_disallowed(:update_subscription)
end
+
it 'allows guests to view' do
expect(permissions(guest, issue)).to be_allowed(:read_issue)
end
+
it 'allows guests to comment' do
expect(permissions(guest, issue)).to be_allowed(:create_note)
end
+
it 'allows guests to subscribe' do
expect(permissions(guest, issue)).to be_allowed(:update_subscription)
end