diff options
author | Rémy Coutable <remy@rymai.me> | 2016-07-05 15:24:58 +0300 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2016-07-05 15:35:26 +0300 |
commit | 22ba5d8a7f0920f39ba33bdc4af54531ffe40b1e (patch) | |
tree | 2178ba63c281c892c693f214871b32ab2214a50a /spec/features/projects/members/member_cannot_request_access_to_his_project_spec.rb | |
parent | aad62735a4643f851047c11eca9eb188d0ef8c77 (diff) |
New :request_access ability to replace a ugly helper
- Group / project members cannot request access
- Group members cannot request access to a group's project
This addresses an issue where project owners could request access
to their own project, leading to UI inconsistency where their requester
status would replace their owner status.
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'spec/features/projects/members/member_cannot_request_access_to_his_project_spec.rb')
-rw-r--r-- | spec/features/projects/members/member_cannot_request_access_to_his_project_spec.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/spec/features/projects/members/member_cannot_request_access_to_his_project_spec.rb b/spec/features/projects/members/member_cannot_request_access_to_his_project_spec.rb new file mode 100644 index 00000000000..9564347e733 --- /dev/null +++ b/spec/features/projects/members/member_cannot_request_access_to_his_project_spec.rb @@ -0,0 +1,16 @@ +require 'spec_helper' + +feature 'Projects > Members > Member cannot request access to his project', feature: true do + let(:member) { create(:user) } + let(:project) { create(:project) } + + background do + project.team << [member, :developer] + login_as(member) + visit namespace_project_path(project.namespace, project) + end + + scenario 'member does not see the request access button' do + expect(page).not_to have_content 'Request Access' + end +end |