diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-17 00:12:07 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-08-17 00:12:07 +0300 |
commit | 2571f434015308eccb425059ad5e82851521265a (patch) | |
tree | a323b0a704a287e8e94d25e2480f321d13bab6cc /spec/policies/issue_policy_spec.rb | |
parent | 8a9790b0db723db32f8dff511ee032e5e8e3b583 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/policies/issue_policy_spec.rb')
-rw-r--r-- | spec/policies/issue_policy_spec.rb | 5 |
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 |