diff options
Diffstat (limited to 'features/steps/shared/group.rb')
-rw-r--r-- | features/steps/shared/group.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/features/steps/shared/group.rb b/features/steps/shared/group.rb index de119f2c6c0..0a0588346b1 100644 --- a/features/steps/shared/group.rb +++ b/features/steps/shared/group.rb @@ -36,14 +36,12 @@ module SharedGroup protected def is_member_of(username, groupname, role) - @project_count ||= 0 user = User.find_by(name: username) || create(:user, name: username) group = Group.find_by(name: groupname) || create(:group, name: groupname) group.add_user(user, role) - project ||= create(:project, :repository, namespace: group, path: "project#{@project_count}") + project ||= create(:project, :repository, namespace: group) create(:closed_issue_event, project: project) - project.team << [user, :master] - @project_count += 1 + project.add_master(user) end def owned_group |