Commit 6c967c2b authored by Rémy Coutable's avatar Rémy Coutable

Merge branch '36782-replace-team-user-role-with-add_role-user-in-specs' into 'master'

Resolve "Replace '.team << [user, role]' with 'add_role(user)' in specs"

Closes #36782

See merge request gitlab-org/gitlab-ce!16069
parents 5512f0aa 27c95364
...@@ -226,7 +226,7 @@ class Project < ActiveRecord::Base ...@@ -226,7 +226,7 @@ class Project < ActiveRecord::Base
delegate :name, to: :owner, allow_nil: true, prefix: true delegate :name, to: :owner, allow_nil: true, prefix: true
delegate :members, to: :team, prefix: true delegate :members, to: :team, prefix: true
delegate :add_user, :add_users, to: :team delegate :add_user, :add_users, to: :team
delegate :add_guest, :add_reporter, :add_developer, :add_master, to: :team delegate :add_guest, :add_reporter, :add_developer, :add_master, :add_role, to: :team
# Validations # Validations
validates :creator, presence: true, on: :create validates :creator, presence: true, on: :create
......
...@@ -7,36 +7,24 @@ class ProjectTeam ...@@ -7,36 +7,24 @@ class ProjectTeam
@project = project @project = project
end end
# Shortcut to add users
#
# Use:
# @team << [@user, :master]
# @team << [@users, :master]
#
def <<(args)
users, access, current_user = *args
if users.respond_to?(:each)
add_users(users, access, current_user: current_user)
else
add_user(users, access, current_user: current_user)
end
end
def add_guest(user, current_user: nil) def add_guest(user, current_user: nil)
self << [user, :guest, current_user] add_user(user, :guest, current_user: current_user)
end end
def add_reporter(user, current_user: nil) def add_reporter(user, current_user: nil)
self << [user, :reporter, current_user] add_user(user, :reporter, current_user: current_user)
end end
def add_developer(user, current_user: nil) def add_developer(user, current_user: nil)
self << [user, :developer, current_user] add_user(user, :developer, current_user: current_user)
end end
def add_master(user, current_user: nil) def add_master(user, current_user: nil)
self << [user, :master, current_user] add_user(user, :master, current_user: current_user)
end
def add_role(user, role, current_user: nil)
send(:"add_#{role}", user, current_user: current_user) # rubocop:disable GitlabSecurity/PublicSend
end end
def find_member(user_id) def find_member(user_id)
......
---
title: Replace '.team << [user, role]' with 'add_role(user)' in specs
merge_request: 16069
author: "@blackst0ne"
type: other
...@@ -14,7 +14,7 @@ Sidekiq::Testing.inline! do ...@@ -14,7 +14,7 @@ Sidekiq::Testing.inline! do
Project.all.each do |project| Project.all.each do |project|
User.all.sample(4).each do |user| User.all.sample(4).each do |user|
if project.team << [user, Gitlab::Access.values.sample] if project.add_role(user, Gitlab::Access.values.sample)
print '.' print '.'
else else
print 'F' print 'F'
......
...@@ -165,7 +165,7 @@ class Spinach::Features::Profile < Spinach::FeatureSteps ...@@ -165,7 +165,7 @@ class Spinach::Features::Profile < Spinach::FeatureSteps
@project = create(:project, :repository, namespace: @group) @project = create(:project, :repository, namespace: @group)
@event = create(:closed_issue_event, project: @project) @event = create(:closed_issue_event, project: @project)
@project.team << [current_user, :master] @project.add_master(current_user)
end end
step 'I should see groups I belong to' do step 'I should see groups I belong to' do
......
...@@ -48,11 +48,11 @@ class Spinach::Features::ProjectDeployKeys < Spinach::FeatureSteps ...@@ -48,11 +48,11 @@ class Spinach::Features::ProjectDeployKeys < Spinach::FeatureSteps
step 'other projects have deploy keys' do step 'other projects have deploy keys' do
@second_project = create(:project, namespace: create(:group)) @second_project = create(:project, namespace: create(:group))
@second_project.team << [current_user, :master] @second_project.add_master(current_user)
create(:deploy_keys_project, project: @second_project) create(:deploy_keys_project, project: @second_project)
@third_project = create(:project, namespace: create(:group)) @third_project = create(:project, namespace: create(:group))
@third_project.team << [current_user, :master] @third_project.add_master(current_user)
create(:deploy_keys_project, project: @third_project, deploy_key: @second_project.deploy_keys.first) create(:deploy_keys_project, project: @third_project, deploy_key: @second_project.deploy_keys.first)
end end
......
...@@ -10,7 +10,7 @@ class Spinach::Features::ProjectFork < Spinach::FeatureSteps ...@@ -10,7 +10,7 @@ class Spinach::Features::ProjectFork < Spinach::FeatureSteps
step 'I am a member of project "Shop"' do step 'I am a member of project "Shop"' do
@project = create(:project, :repository, name: "Shop") @project = create(:project, :repository, name: "Shop")
@project.team << [@user, :reporter] @project.add_reporter(@user)
end end
step 'I should see the forked project page' do step 'I should see the forked project page' do
...@@ -71,7 +71,7 @@ class Spinach::Features::ProjectFork < Spinach::FeatureSteps ...@@ -71,7 +71,7 @@ class Spinach::Features::ProjectFork < Spinach::FeatureSteps
step 'There is an existent fork of the "Shop" project' do step 'There is an existent fork of the "Shop" project' do
user = create(:user, name: 'Mike') user = create(:user, name: 'Mike')
@project.team << [user, :reporter] @project.add_reporter(user)
@forked_project = Projects::ForkService.new(@project, user).execute @forked_project = Projects::ForkService.new(@project, user).execute
end end
......
...@@ -10,7 +10,7 @@ class Spinach::Features::ProjectForkedMergeRequests < Spinach::FeatureSteps ...@@ -10,7 +10,7 @@ class Spinach::Features::ProjectForkedMergeRequests < Spinach::FeatureSteps
step 'I am a member of project "Shop"' do step 'I am a member of project "Shop"' do
@project = ::Project.find_by(name: "Shop") @project = ::Project.find_by(name: "Shop")
@project ||= create(:project, :repository, name: "Shop") @project ||= create(:project, :repository, name: "Shop")
@project.team << [@user, :reporter] @project.add_reporter(@user)
end end
step 'I have a project forked off of "Shop" called "Forked Shop"' do step 'I have a project forked off of "Shop" called "Forked Shop"' do
......
...@@ -8,7 +8,7 @@ class Spinach::Features::ProjectSourceBrowseFiles < Spinach::FeatureSteps ...@@ -8,7 +8,7 @@ class Spinach::Features::ProjectSourceBrowseFiles < Spinach::FeatureSteps
step "I don't have write access" do step "I don't have write access" do
@project = create(:project, :repository, name: "Other Project", path: "other-project") @project = create(:project, :repository, name: "Other Project", path: "other-project")
@project.team << [@user, :reporter] @project.add_reporter(@user)
visit project_tree_path(@project, root_ref) visit project_tree_path(@project, root_ref)
end end
......
...@@ -10,7 +10,7 @@ class Spinach::Features::ProjectSourceMarkdownRender < Spinach::FeatureSteps ...@@ -10,7 +10,7 @@ class Spinach::Features::ProjectSourceMarkdownRender < Spinach::FeatureSteps
step 'I own project "Delta"' do step 'I own project "Delta"' do
@project = ::Project.find_by(name: "Delta") @project = ::Project.find_by(name: "Delta")
@project ||= create(:project, :repository, name: "Delta", namespace: @user.namespace) @project ||= create(:project, :repository, name: "Delta", namespace: @user.namespace)
@project.team << [@user, :master] @project.add_master(@user)
end end
step 'I should see files from repository in markdown' do step 'I should see files from repository in markdown' do
......
...@@ -41,7 +41,7 @@ module SharedGroup ...@@ -41,7 +41,7 @@ module SharedGroup
group.add_user(user, role) group.add_user(user, role)
project ||= create(:project, :repository, namespace: group) project ||= create(:project, :repository, namespace: group)
create(:closed_issue_event, project: project) create(:closed_issue_event, project: project)
project.team << [user, :master] project.add_master(user)
end end
def owned_group def owned_group
......
...@@ -4,13 +4,13 @@ module SharedProject ...@@ -4,13 +4,13 @@ module SharedProject
# Create a project without caring about what it's called # Create a project without caring about what it's called
step "I own a project" do step "I own a project" do
@project = create(:project, :repository, namespace: @user.namespace) @project = create(:project, :repository, namespace: @user.namespace)
@project.team << [@user, :master] @project.add_master(@user)
end end
step "I own a project in some group namespace" do step "I own a project in some group namespace" do
@group = create(:group, name: 'some group') @group = create(:group, name: 'some group')
@project = create(:project, namespace: @group) @project = create(:project, namespace: @group)
@project.team << [@user, :master] @project.add_master(@user)
end end
step "project exists in some group namespace" do step "project exists in some group namespace" do
...@@ -22,7 +22,7 @@ module SharedProject ...@@ -22,7 +22,7 @@ module SharedProject
step 'I own project "Shop"' do step 'I own project "Shop"' do
@project = Project.find_by(name: "Shop") @project = Project.find_by(name: "Shop")
@project ||= create(:project, :repository, name: "Shop", namespace: @user.namespace) @project ||= create(:project, :repository, name: "Shop", namespace: @user.namespace)
@project.team << [@user, :master] @project.add_master(@user)
end end
step 'I disable snippets in project' do step 'I disable snippets in project' do
...@@ -40,7 +40,7 @@ module SharedProject ...@@ -40,7 +40,7 @@ module SharedProject
step 'I add a user to project "Shop"' do step 'I add a user to project "Shop"' do
@project = Project.find_by(name: "Shop") @project = Project.find_by(name: "Shop")
other_user = create(:user, name: 'Alpha') other_user = create(:user, name: 'Alpha')
@project.team << [other_user, :master] @project.add_master(other_user)
end end
# Create another specific project called "Forum" # Create another specific project called "Forum"
...@@ -49,14 +49,13 @@ module SharedProject ...@@ -49,14 +49,13 @@ module SharedProject
@project ||= create(:project, :repository, name: "Forum", namespace: @user.namespace, path: 'forum_project') @project ||= create(:project, :repository, name: "Forum", namespace: @user.namespace, path: 'forum_project')
@project.build_project_feature @project.build_project_feature
@project.project_feature.save @project.project_feature.save
@project.team << [@user, :master] @project.add_master(@user)
end end
# Create an empty project without caring about the name # Create an empty project without caring about the name
step 'I own an empty project' do step 'I own an empty project' do
@project = create(:project, @project = create(:project, name: 'Empty Project', namespace: @user.namespace)
name: 'Empty Project', namespace: @user.namespace) @project.add_master(@user)
@project.team << [@user, :master]
end end
step 'I visit my empty project page' do step 'I visit my empty project page' do
...@@ -101,11 +100,11 @@ module SharedProject ...@@ -101,11 +100,11 @@ module SharedProject
# ---------------------------------------- # ----------------------------------------
step 'I am member of a project with a guest role' do step 'I am member of a project with a guest role' do
@project.team << [@user, Gitlab::Access::GUEST] @project.add_guest(@user)
end end
step 'I am member of a project with a reporter role' do step 'I am member of a project with a reporter role' do
@project.team << [@user, Gitlab::Access::REPORTER] @project.add_reporter(@user)
end end
# ---------------------------------------- # ----------------------------------------
...@@ -245,6 +244,6 @@ module SharedProject ...@@ -245,6 +244,6 @@ module SharedProject
user = user_exists(user_name, username: user_name.gsub(/\s/, '').underscore) user = user_exists(user_name, username: user_name.gsub(/\s/, '').underscore)
project = Project.find_by(name: project_name) project = Project.find_by(name: project_name)
project ||= create(:project, visibility, name: project_name, namespace: user.namespace) project ||= create(:project, visibility, name: project_name, namespace: user.namespace)
project.team << [user, :master] project.add_master(user)
end end
end end
...@@ -13,7 +13,7 @@ describe Admin::UsersController do ...@@ -13,7 +13,7 @@ describe Admin::UsersController do
let!(:issue) { create(:issue, author: user) } let!(:issue) { create(:issue, author: user) }
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
it 'deletes user and ghosts their contributions' do it 'deletes user and ghosts their contributions' do
......
...@@ -13,8 +13,8 @@ describe Boards::IssuesController do ...@@ -13,8 +13,8 @@ describe Boards::IssuesController do
let!(:list2) { create(:list, board: board, label: development, position: 1) } let!(:list2) { create(:list, board: board, label: development, position: 1) }
before do before do
project.team << [user, :master] project.add_master(user)
project.team << [guest, :guest] project.add_guest(guest)
end end
describe 'GET index' do describe 'GET index' do
...@@ -221,7 +221,7 @@ describe Boards::IssuesController do ...@@ -221,7 +221,7 @@ describe Boards::IssuesController do
let(:guest) { create(:user) } let(:guest) { create(:user) }
before do before do
project.team << [guest, :guest] project.add_guest(guest)
end end
it 'returns a forbidden 403 response' do it 'returns a forbidden 403 response' do
......
...@@ -7,8 +7,8 @@ describe Boards::ListsController do ...@@ -7,8 +7,8 @@ describe Boards::ListsController do
let(:guest) { create(:user) } let(:guest) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
project.team << [guest, :guest] project.add_guest(guest)
end end
describe 'GET index' do describe 'GET index' do
......
...@@ -17,7 +17,7 @@ describe Dashboard::MilestonesController do ...@@ -17,7 +17,7 @@ describe Dashboard::MilestonesController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
end end
it_behaves_like 'milestone tabs' it_behaves_like 'milestone tabs'
......
...@@ -8,7 +8,7 @@ describe Dashboard::TodosController do ...@@ -8,7 +8,7 @@ describe Dashboard::TodosController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
describe 'GET #index' do describe 'GET #index' do
......
...@@ -5,7 +5,7 @@ describe DashboardController do ...@@ -5,7 +5,7 @@ describe DashboardController do
let(:project) { create(:project) } let(:project) { create(:project) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -28,7 +28,7 @@ describe Groups::MilestonesController do ...@@ -28,7 +28,7 @@ describe Groups::MilestonesController do
before do before do
sign_in(user) sign_in(user)
group.add_owner(user) group.add_owner(user)
project.team << [user, :master] project.add_master(user)
end end
describe '#index' do describe '#index' do
......
...@@ -6,7 +6,7 @@ describe NotificationSettingsController do ...@@ -6,7 +6,7 @@ describe NotificationSettingsController do
let(:user) { create(:user) } let(:user) { create(:user) }
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
describe '#create' do describe '#create' do
......
...@@ -6,7 +6,7 @@ describe Projects::AvatarsController do ...@@ -6,7 +6,7 @@ describe Projects::AvatarsController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
controller.instance_variable_set(:@project, project) controller.instance_variable_set(:@project, project)
end end
......
...@@ -7,7 +7,7 @@ describe Projects::BlameController do ...@@ -7,7 +7,7 @@ describe Projects::BlameController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
controller.instance_variable_set(:@project, project) controller.instance_variable_set(:@project, project)
end end
......
...@@ -89,7 +89,7 @@ describe Projects::BlobController do ...@@ -89,7 +89,7 @@ describe Projects::BlobController do
end end
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
...@@ -147,7 +147,7 @@ describe Projects::BlobController do ...@@ -147,7 +147,7 @@ describe Projects::BlobController do
let(:developer) { create(:user) } let(:developer) { create(:user) }
before do before do
project.team << [developer, :developer] project.add_developer(developer)
sign_in(developer) sign_in(developer)
get :edit, default_params get :edit, default_params
end end
...@@ -161,7 +161,7 @@ describe Projects::BlobController do ...@@ -161,7 +161,7 @@ describe Projects::BlobController do
let(:master) { create(:user) } let(:master) { create(:user) }
before do before do
project.team << [master, :master] project.add_master(master)
sign_in(master) sign_in(master)
get :edit, default_params get :edit, default_params
end end
...@@ -190,7 +190,7 @@ describe Projects::BlobController do ...@@ -190,7 +190,7 @@ describe Projects::BlobController do
end end
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -5,7 +5,7 @@ describe Projects::BoardsController do ...@@ -5,7 +5,7 @@ describe Projects::BoardsController do
let(:user) { create(:user) } let(:user) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -6,8 +6,8 @@ describe Projects::BranchesController do ...@@ -6,8 +6,8 @@ describe Projects::BranchesController do
let(:developer) { create(:user) } let(:developer) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
project.team << [user, :developer] project.add_developer(user)
allow(project).to receive(:branches).and_return(['master', 'foo/bar/baz']) allow(project).to receive(:branches).and_return(['master', 'foo/bar/baz'])
allow(project).to receive(:tags).and_return(['v1.0.0', 'v2.0.0']) allow(project).to receive(:tags).and_return(['v1.0.0', 'v2.0.0'])
......
...@@ -6,7 +6,7 @@ describe Projects::CommitsController do ...@@ -6,7 +6,7 @@ describe Projects::CommitsController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
end end
describe "GET show" do describe "GET show" do
......
...@@ -8,7 +8,7 @@ describe Projects::CompareController do ...@@ -8,7 +8,7 @@ describe Projects::CompareController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
end end
it 'compare shows some diffs' do it 'compare shows some diffs' do
......
...@@ -6,7 +6,7 @@ describe Projects::CycleAnalyticsController do ...@@ -6,7 +6,7 @@ describe Projects::CycleAnalyticsController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
end end
describe 'cycle analytics not set up flag' do describe 'cycle analytics not set up flag' do
......
...@@ -5,7 +5,7 @@ describe Projects::DeployKeysController do ...@@ -5,7 +5,7 @@ describe Projects::DeployKeysController do
let(:user) { create(:user) } let(:user) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
...@@ -48,7 +48,7 @@ describe Projects::DeployKeysController do ...@@ -48,7 +48,7 @@ describe Projects::DeployKeysController do
end end
before do before do
project2.team << [user, :developer] project2.add_developer(user)
end end
it 'returns json in a correct format' do it 'returns json in a correct format' do
......
...@@ -8,7 +8,7 @@ describe Projects::DeploymentsController do ...@@ -8,7 +8,7 @@ describe Projects::DeploymentsController do
let(:environment) { create(:environment, name: 'production', project: project) } let(:environment) { create(:environment, name: 'production', project: project) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -31,7 +31,7 @@ describe Projects::DiscussionsController do ...@@ -31,7 +31,7 @@ describe Projects::DiscussionsController do
context "when the user is authorized to resolve the discussion" do context "when the user is authorized to resolve the discussion" do
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
context "when the discussion is not resolvable" do context "when the discussion is not resolvable" do
...@@ -92,7 +92,7 @@ describe Projects::DiscussionsController do ...@@ -92,7 +92,7 @@ describe Projects::DiscussionsController do
context "when the user is authorized to resolve the discussion" do context "when the user is authorized to resolve the discussion" do
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
context "when the discussion is not resolvable" do context "when the discussion is not resolvable" do
......
...@@ -7,7 +7,7 @@ describe Projects::FindFileController do ...@@ -7,7 +7,7 @@ describe Projects::FindFileController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
controller.instance_variable_set(:@project, project) controller.instance_variable_set(:@project, project)
end end
......
...@@ -51,7 +51,7 @@ describe Projects::ForksController do ...@@ -51,7 +51,7 @@ describe Projects::ForksController do
context 'when user is a member of the Project' do context 'when user is a member of the Project' do
before do before do
forked_project.team << [project.creator, :developer] forked_project.add_developer(project.creator)
end end
it 'sees the project listed' do it 'sees the project listed' do
......
...@@ -6,7 +6,7 @@ describe Projects::GraphsController do ...@@ -6,7 +6,7 @@ describe Projects::GraphsController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
end end
describe 'GET languages' do describe 'GET languages' do
......
...@@ -7,7 +7,7 @@ describe Projects::GroupLinksController do ...@@ -7,7 +7,7 @@ describe Projects::GroupLinksController do
let(:user) { create(:user) } let(:user) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -5,7 +5,7 @@ describe Projects::HooksController do ...@@ -5,7 +5,7 @@ describe Projects::HooksController do
let(:user) { create(:user) } let(:user) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -9,7 +9,7 @@ describe Projects::ImportsController do ...@@ -9,7 +9,7 @@ describe Projects::ImportsController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
end end
it 'renders template' do it 'renders template' do
...@@ -30,7 +30,7 @@ describe Projects::ImportsController do ...@@ -30,7 +30,7 @@ describe Projects::ImportsController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
end end
context 'when import is in progress' do context 'when import is in progress' do
......
...@@ -37,7 +37,7 @@ describe Projects::IssuesController do ...@@ -37,7 +37,7 @@ describe Projects::IssuesController do
context 'internal issue tracker' do context 'internal issue tracker' do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
it_behaves_like "issuables list meta-data", :issue it_behaves_like "issuables list meta-data", :issue
...@@ -69,7 +69,7 @@ describe Projects::IssuesController do ...@@ -69,7 +69,7 @@ describe Projects::IssuesController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
allow(Kaminari.config).to receive(:default_per_page).and_return(1) allow(Kaminari.config).to receive(:default_per_page).and_return(1)
end end
...@@ -116,7 +116,7 @@ describe Projects::IssuesController do ...@@ -116,7 +116,7 @@ describe Projects::IssuesController do
context 'internal issue tracker' do context 'internal issue tracker' do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
it 'builds a new issue' do it 'builds a new issue' do
...@@ -127,7 +127,7 @@ describe Projects::IssuesController do ...@@ -127,7 +127,7 @@ describe Projects::IssuesController do
it 'fills in an issue for a merge request' do it 'fills in an issue for a merge request' do
project_with_repository = create(:project, :repository) project_with_repository = create(:project, :repository)
project_with_repository.team << [user, :developer] project_with_repository.add_developer(user)
mr = create(:merge_request_with_diff_notes, source_project: project_with_repository) mr = create(:merge_request_with_diff_notes, source_project: project_with_repository)
get :new, namespace_id: project_with_repository.namespace, project_id: project_with_repository, merge_request_to_resolve_discussions_of: mr.iid get :new, namespace_id: project_with_repository.namespace, project_id: project_with_repository, merge_request_to_resolve_discussions_of: mr.iid
...@@ -153,7 +153,7 @@ describe Projects::IssuesController do ...@@ -153,7 +153,7 @@ describe Projects::IssuesController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
external = double external = double
allow(project).to receive(:external_issue_tracker).and_return(external) allow(project).to receive(:external_issue_tracker).and_return(external)
...@@ -329,7 +329,7 @@ describe Projects::IssuesController do ...@@ -329,7 +329,7 @@ describe Projects::IssuesController do
it 'does not list confidential issues for project members with guest role' do it 'does not list confidential issues for project members with guest role' do
sign_in(member) sign_in(member)
project.team << [member, :guest] project.add_guest(member)
get_issues get_issues
...@@ -354,7 +354,7 @@ describe Projects::IssuesController do ...@@ -354,7 +354,7 @@ describe Projects::IssuesController do
it 'lists confidential issues for project members' do it 'lists confidential issues for project members' do
sign_in(member) sign_in(member)
project.team << [member, :developer] project.add_developer(member)
get_issues get_issues
...@@ -394,7 +394,7 @@ describe Projects::IssuesController do ...@@ -394,7 +394,7 @@ describe Projects::IssuesController do
it 'returns 404 for project members with guest role' do it 'returns 404 for project members with guest role' do
sign_in(member) sign_in(member)
project.team << [member, :guest] project.add_guest(member)
go(id: unescaped_parameter_value.to_param) go(id: unescaped_parameter_value.to_param)
expect(response).to have_gitlab_http_status :not_found expect(response).to have_gitlab_http_status :not_found
...@@ -416,7 +416,7 @@ describe Projects::IssuesController do ...@@ -416,7 +416,7 @@ describe Projects::IssuesController do
it "returns #{http_status[:success]} for project members" do it "returns #{http_status[:success]} for project members" do
sign_in(member) sign_in(member)
project.team << [member, :developer] project.add_developer(member)
go(id: unescaped_parameter_value.to_param) go(id: unescaped_parameter_value.to_param)
expect(response).to have_gitlab_http_status http_status[:success] expect(response).to have_gitlab_http_status http_status[:success]
...@@ -450,7 +450,7 @@ describe Projects::IssuesController do ...@@ -450,7 +450,7 @@ describe Projects::IssuesController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
it_behaves_like 'restricted action', success: 200 it_behaves_like 'restricted action', success: 200
...@@ -594,7 +594,7 @@ describe Projects::IssuesController do ...@@ -594,7 +594,7 @@ describe Projects::IssuesController do
let(:deleted_user) { create(:user) } let(:deleted_user) { create(:user) }
before do before do
project.team << [user, :developer] project.add_developer(user)
issue.update!(last_edited_by: deleted_user, last_edited_at: Time.now) issue.update!(last_edited_by: deleted_user, last_edited_at: Time.now)
...@@ -638,7 +638,7 @@ describe Projects::IssuesController do ...@@ -638,7 +638,7 @@ describe Projects::IssuesController do
def post_new_issue(issue_attrs = {}, additional_params = {}) def post_new_issue(issue_attrs = {}, additional_params = {})
sign_in(user) sign_in(user)
project = create(:project, :public) project = create(:project, :public)
project.team << [user, :developer] project.add_developer(user)
post :create, { post :create, {
namespace_id: project.namespace.to_param, namespace_id: project.namespace.to_param,
...@@ -655,7 +655,7 @@ describe Projects::IssuesController do ...@@ -655,7 +655,7 @@ describe Projects::IssuesController do
let(:project) { merge_request.source_project } let(:project) { merge_request.source_project }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in user sign_in user
end end
...@@ -829,7 +829,7 @@ describe Projects::IssuesController do ...@@ -829,7 +829,7 @@ describe Projects::IssuesController do
def post_spam def post_spam
admin = create(:admin) admin = create(:admin)
create(:user_agent_detail, subject: issue) create(:user_agent_detail, subject: issue)
project.team << [admin, :master] project.add_master(admin)
sign_in(admin) sign_in(admin)
post :mark_as_spam, { post :mark_as_spam, {
namespace_id: project.namespace, namespace_id: project.namespace,
......
...@@ -374,7 +374,7 @@ describe Projects::JobsController do ...@@ -374,7 +374,7 @@ describe Projects::JobsController do
let(:role) { :master } let(:role) { :master }
before do before do
project.team << [user, role] project.add_role(user, role)
sign_in(user) sign_in(user)
post_erase post_erase
......
...@@ -6,7 +6,7 @@ describe Projects::LabelsController do ...@@ -6,7 +6,7 @@ describe Projects::LabelsController do
let(:user) { create(:user) } let(:user) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -5,7 +5,7 @@ describe Projects::MattermostsController do ...@@ -5,7 +5,7 @@ describe Projects::MattermostsController do
let!(:user) { create(:user) } let!(:user) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -6,7 +6,7 @@ describe Projects::MergeRequests::CreationsController do ...@@ -6,7 +6,7 @@ describe Projects::MergeRequests::CreationsController do
let(:fork_project) { create(:forked_project_with_submodules) } let(:fork_project) { create(:forked_project_with_submodules) }
before do before do
fork_project.team << [user, :master] fork_project.add_master(user)
sign_in(user) sign_in(user)
end end
...@@ -86,7 +86,7 @@ describe Projects::MergeRequests::CreationsController do ...@@ -86,7 +86,7 @@ describe Projects::MergeRequests::CreationsController do
let(:other_project) { create(:project, :repository) } let(:other_project) { create(:project, :repository) }
before do before do
other_project.team << [user, :master] other_project.add_master(user)
end end
context 'when the path exists in the diff' do context 'when the path exists in the diff' do
......
...@@ -151,7 +151,7 @@ describe Projects::MergeRequests::DiffsController do ...@@ -151,7 +151,7 @@ describe Projects::MergeRequests::DiffsController do
let(:other_project) { create(:project) } let(:other_project) { create(:project) }
before do before do
other_project.team << [user, :master] other_project.add_master(user)
diff_for_path(old_path: existing_path, new_path: existing_path, project_id: other_project) diff_for_path(old_path: existing_path, new_path: existing_path, project_id: other_project)
end end
......
...@@ -11,7 +11,7 @@ describe Projects::MilestonesController do ...@@ -11,7 +11,7 @@ describe Projects::MilestonesController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
controller.instance_variable_set(:@project, project) controller.instance_variable_set(:@project, project)
end end
......
...@@ -32,7 +32,7 @@ describe Projects::NotesController do ...@@ -32,7 +32,7 @@ describe Projects::NotesController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
it 'passes last_fetched_at from headers to NotesFinder' do it 'passes last_fetched_at from headers to NotesFinder' do
...@@ -351,7 +351,7 @@ describe Projects::NotesController do ...@@ -351,7 +351,7 @@ describe Projects::NotesController do
before do before do
sign_in(note.author) sign_in(note.author)
project.team << [note.author, :developer] project.add_developer(note.author)
end end
it "updates the note" do it "updates the note" do
...@@ -372,7 +372,7 @@ describe Projects::NotesController do ...@@ -372,7 +372,7 @@ describe Projects::NotesController do
context 'user is the author of a note' do context 'user is the author of a note' do
before do before do
sign_in(note.author) sign_in(note.author)
project.team << [note.author, :developer] project.add_developer(note.author)
end end
it "returns status 200 for html" do it "returns status 200 for html" do
...@@ -389,7 +389,7 @@ describe Projects::NotesController do ...@@ -389,7 +389,7 @@ describe Projects::NotesController do
context 'user is not the author of a note' do context 'user is not the author of a note' do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
it "returns status 404" do it "returns status 404" do
...@@ -403,7 +403,7 @@ describe Projects::NotesController do ...@@ -403,7 +403,7 @@ describe Projects::NotesController do
describe 'POST toggle_award_emoji' do describe 'POST toggle_award_emoji' do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
it "toggles the award emoji" do it "toggles the award emoji" do
...@@ -445,7 +445,7 @@ describe Projects::NotesController do ...@@ -445,7 +445,7 @@ describe Projects::NotesController do
context "when the user is authorized to resolve the note" do context "when the user is authorized to resolve the note" do
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
context "when the note is not resolvable" do context "when the note is not resolvable" do
...@@ -506,7 +506,7 @@ describe Projects::NotesController do ...@@ -506,7 +506,7 @@ describe Projects::NotesController do
context "when the user is authorized to resolve the note" do context "when the user is authorized to resolve the note" do
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
context "when the note is not resolvable" do context "when the note is not resolvable" do
......
...@@ -21,7 +21,7 @@ describe Projects::ProjectMembersController do ...@@ -21,7 +21,7 @@ describe Projects::ProjectMembersController do
context 'when user does not have enough rights' do context 'when user does not have enough rights' do
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
it 'returns 404' do it 'returns 404' do
...@@ -37,7 +37,7 @@ describe Projects::ProjectMembersController do ...@@ -37,7 +37,7 @@ describe Projects::ProjectMembersController do
context 'when user has enough rights' do context 'when user has enough rights' do
before do before do
project.team << [user, :master] project.add_master(user)
end end
it 'adds user to members' do it 'adds user to members' do
...@@ -106,7 +106,7 @@ describe Projects::ProjectMembersController do ...@@ -106,7 +106,7 @@ describe Projects::ProjectMembersController do
context 'when member is found' do context 'when member is found' do
context 'when user does not have enough rights' do context 'when user does not have enough rights' do
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
it 'returns 404' do it 'returns 404' do
...@@ -121,7 +121,7 @@ describe Projects::ProjectMembersController do ...@@ -121,7 +121,7 @@ describe Projects::ProjectMembersController do
context 'when user has enough rights' do context 'when user has enough rights' do
before do before do
project.team << [user, :master] project.add_master(user)
end end
it '[HTML] removes user from members' do it '[HTML] removes user from members' do
...@@ -164,7 +164,7 @@ describe Projects::ProjectMembersController do ...@@ -164,7 +164,7 @@ describe Projects::ProjectMembersController do
context 'when member is found' do context 'when member is found' do
context 'and is not an owner' do context 'and is not an owner' do
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
it 'removes user from members' do it 'removes user from members' do
...@@ -181,7 +181,7 @@ describe Projects::ProjectMembersController do ...@@ -181,7 +181,7 @@ describe Projects::ProjectMembersController do
let(:project) { create(:project, namespace: user.namespace) } let(:project) { create(:project, namespace: user.namespace) }
before do before do
project.team << [user, :master] project.add_master(user)
end end
it 'cannot remove himself from the project' do it 'cannot remove himself from the project' do
...@@ -248,7 +248,7 @@ describe Projects::ProjectMembersController do ...@@ -248,7 +248,7 @@ describe Projects::ProjectMembersController do
context 'when member is found' do context 'when member is found' do
context 'when user does not have enough rights' do context 'when user does not have enough rights' do
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
it 'returns 404' do it 'returns 404' do
...@@ -263,7 +263,7 @@ describe Projects::ProjectMembersController do ...@@ -263,7 +263,7 @@ describe Projects::ProjectMembersController do
context 'when user has enough rights' do context 'when user has enough rights' do
before do before do
project.team << [user, :master] project.add_master(user)
end end
it 'adds user to members' do it 'adds user to members' do
...@@ -285,8 +285,8 @@ describe Projects::ProjectMembersController do ...@@ -285,8 +285,8 @@ describe Projects::ProjectMembersController do
let(:member) { create(:user) } let(:member) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
another_project.team << [member, :guest] another_project.add_guest(member)
sign_in(user) sign_in(user)
end end
...@@ -300,7 +300,7 @@ describe Projects::ProjectMembersController do ...@@ -300,7 +300,7 @@ describe Projects::ProjectMembersController do
context 'when user can access source project members' do context 'when user can access source project members' do
before do before do
another_project.team << [user, :guest] another_project.add_guest(user)
end end
include_context 'import applied' include_context 'import applied'
...@@ -332,7 +332,7 @@ describe Projects::ProjectMembersController do ...@@ -332,7 +332,7 @@ describe Projects::ProjectMembersController do
context 'when creating owner' do context 'when creating owner' do
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
...@@ -348,7 +348,7 @@ describe Projects::ProjectMembersController do ...@@ -348,7 +348,7 @@ describe Projects::ProjectMembersController do
context 'when create master' do context 'when create master' do
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -6,7 +6,7 @@ describe Projects::RefsController do ...@@ -6,7 +6,7 @@ describe Projects::RefsController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
describe 'GET #logs_tree' do describe 'GET #logs_tree' do
......
...@@ -7,7 +7,7 @@ describe Projects::ReleasesController do ...@@ -7,7 +7,7 @@ describe Projects::ReleasesController do
let!(:tag) { release.tag } let!(:tag) { release.tag }
before do before do
project.team << [user, :developer] project.add_developer(user)
sign_in(user) sign_in(user)
end end
......
...@@ -17,7 +17,7 @@ describe Projects::RepositoriesController do ...@@ -17,7 +17,7 @@ describe Projects::RepositoriesController do
let(:user) { create(:user) } let(:user) { create(:user) }
before do before do
project.team << [user, :developer] project.add_developer(user)
sign_in(user) sign_in(user)
end end
......
...@@ -9,7 +9,7 @@ describe Projects::ServicesController do ...@@ -9,7 +9,7 @@ describe Projects::ServicesController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
end end
describe '#test' do describe '#test' do
......
...@@ -5,7 +5,7 @@ describe Projects::Settings::CiCdController do ...@@ -5,7 +5,7 @@ describe Projects::Settings::CiCdController do
let(:user) { create(:user) } let(:user) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -5,7 +5,7 @@ describe Projects::Settings::IntegrationsController do ...@@ -5,7 +5,7 @@ describe Projects::Settings::IntegrationsController do
let(:user) { create(:user) } let(:user) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -8,7 +8,7 @@ describe Projects::TemplatesController do ...@@ -8,7 +8,7 @@ describe Projects::TemplatesController do
let(:body) { JSON.parse(response.body) } let(:body) { JSON.parse(response.body) }
before do before do
project.team << [user, :developer] project.add_developer(user)
sign_in(user) sign_in(user)
end end
......
...@@ -20,7 +20,7 @@ describe Projects::TodosController do ...@@ -20,7 +20,7 @@ describe Projects::TodosController do
context 'when authorized' do context 'when authorized' do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
it 'creates todo for issue' do it 'creates todo for issue' do
...@@ -88,7 +88,7 @@ describe Projects::TodosController do ...@@ -88,7 +88,7 @@ describe Projects::TodosController do
context 'when authorized' do context 'when authorized' do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
it 'creates todo for merge request' do it 'creates todo for merge request' do
......
...@@ -7,7 +7,7 @@ describe Projects::TreeController do ...@@ -7,7 +7,7 @@ describe Projects::TreeController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
controller.instance_variable_set(:@project, project) controller.instance_variable_set(:@project, project)
end end
......
...@@ -6,7 +6,7 @@ describe Projects::VariablesController do ...@@ -6,7 +6,7 @@ describe Projects::VariablesController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :master] project.add_master(user)
end end
describe 'POST #create' do describe 'POST #create' do
......
...@@ -102,7 +102,7 @@ describe ProjectsController do ...@@ -102,7 +102,7 @@ describe ProjectsController do
render_views render_views
before do before do
project.team << [user, :developer] project.add_developer(user)
project.project_feature.update_attribute(:repository_access_level, ProjectFeature::DISABLED) project.project_feature.update_attribute(:repository_access_level, ProjectFeature::DISABLED)
end end
...@@ -437,7 +437,7 @@ describe ProjectsController do ...@@ -437,7 +437,7 @@ describe ProjectsController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
allow(Gitlab.config.incoming_email).to receive(:enabled).and_return(true) allow(Gitlab.config.incoming_email).to receive(:enabled).and_return(true)
end end
...@@ -465,7 +465,7 @@ describe ProjectsController do ...@@ -465,7 +465,7 @@ describe ProjectsController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
allow(Gitlab.config.incoming_email).to receive(:enabled).and_return(true) allow(Gitlab.config.incoming_email).to receive(:enabled).and_return(true)
end end
......
...@@ -265,13 +265,13 @@ describe UploadsController do ...@@ -265,13 +265,13 @@ describe UploadsController do
context "when the user has access to the project" do context "when the user has access to the project" do
before do before do
project.team << [user, :master] project.add_master(user)
end end
context "when the user is blocked" do context "when the user is blocked" do
before do before do
user.block user.block
project.team << [user, :master] project.add_master(user)
end end
it "redirects to the sign in page" do it "redirects to the sign in page" do
...@@ -465,13 +465,13 @@ describe UploadsController do ...@@ -465,13 +465,13 @@ describe UploadsController do
context "when the user has access to the project" do context "when the user has access to the project" do
before do before do
project.team << [user, :master] project.add_master(user)
end end
context "when the user is blocked" do context "when the user is blocked" do
before do before do
user.block user.block
project.team << [user, :master] project.add_master(user)
end end
it "redirects to the sign in page" do it "redirects to the sign in page" do
......
...@@ -91,7 +91,7 @@ describe UsersController do ...@@ -91,7 +91,7 @@ describe UsersController do
before do before do
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
push_data = Gitlab::DataBuilder::Push.build_sample(project, user) push_data = Gitlab::DataBuilder::Push.build_sample(project, user)
...@@ -117,7 +117,7 @@ describe UsersController do ...@@ -117,7 +117,7 @@ describe UsersController do
allow_any_instance_of(User).to receive(:contributed_projects_ids).and_return([project.id]) allow_any_instance_of(User).to receive(:contributed_projects_ids).and_return([project.id])
sign_in(user) sign_in(user)
project.team << [user, :developer] project.add_developer(user)
end end
it 'assigns @calendar_date' do it 'assigns @calendar_date' do
......
...@@ -88,7 +88,7 @@ describe "Admin::Projects" do ...@@ -88,7 +88,7 @@ describe "Admin::Projects" do
describe 'add admin himself to a project' do describe 'add admin himself to a project' do
before do before do
project.team << [user, :master] project.add_master(user)
end end
it 'adds admin a to a project as developer', :js do it 'adds admin a to a project as developer', :js do
...@@ -110,8 +110,8 @@ describe "Admin::Projects" do ...@@ -110,8 +110,8 @@ describe "Admin::Projects" do
describe 'admin remove himself from a project' do describe 'admin remove himself from a project' do
before do before do
project.team << [user, :master] project.add_master(user)
project.team << [current_user, :developer] project.add_developer(current_user)
end end
it 'removes admin from the project' do it 'removes admin from the project' do
......
...@@ -8,8 +8,8 @@ describe "Dashboard Issues Feed" do ...@@ -8,8 +8,8 @@ describe "Dashboard Issues Feed" do
let!(:project2) { create(:project) } let!(:project2) { create(:project) }
before do before do
project1.team << [user, :master] project1.add_master(user)
project2.team << [user, :master] project2.add_master(user)
end end
describe "atom feed" do describe "atom feed" do
......
...@@ -26,7 +26,7 @@ describe "Dashboard Feed" do ...@@ -26,7 +26,7 @@ describe "Dashboard Feed" do
let(:note) { create(:note, noteable: issue, author: user, note: 'Bug confirmed', project: project) } let(:note) { create(:note, noteable: issue, author: user, note: 'Bug confirmed', project: project) }
before do before do
project.team << [user, :master] project.add_master(user)
issue_event(issue, user) issue_event(issue, user)
note_event(note, user) note_event(note, user)
visit dashboard_projects_path(:atom, rss_token: user.rss_token) visit dashboard_projects_path(:atom, rss_token: user.rss_token)
......
...@@ -9,7 +9,7 @@ describe 'Issues Feed' do ...@@ -9,7 +9,7 @@ describe 'Issues Feed' do
let!(:issue) { create(:issue, author: user, assignees: [assignee], project: project) } let!(:issue) { create(:issue, author: user, assignees: [assignee], project: project) }
before do before do
project.team << [user, :developer] project.add_developer(user)
group.add_developer(user) group.add_developer(user)
end end
......
...@@ -47,7 +47,7 @@ describe "User Feed" do ...@@ -47,7 +47,7 @@ describe "User Feed" do
let!(:push_event_payload) { create(:push_event_payload, event: push_event) } let!(:push_event_payload) { create(:push_event_payload, event: push_event) }
before do before do
project.team << [user, :master] project.add_master(user)
issue_event(issue, user) issue_event(issue, user)
note_event(note, user) note_event(note, user)
merge_request_event(merge_request, user) merge_request_event(merge_request, user)
......
...@@ -52,7 +52,7 @@ describe 'Auto deploy' do ...@@ -52,7 +52,7 @@ describe 'Auto deploy' do
context 'when user configured kubernetes from Integration > Kubernetes' do context 'when user configured kubernetes from Integration > Kubernetes' do
before do before do
create :kubernetes_service, project: project create :kubernetes_service, project: project
project.team << [user, :master] project.add_master(user)
sign_in user sign_in user
end end
...@@ -65,7 +65,7 @@ describe 'Auto deploy' do ...@@ -65,7 +65,7 @@ describe 'Auto deploy' do
context 'when user configured kubernetes from CI/CD > Clusters' do context 'when user configured kubernetes from CI/CD > Clusters' do
before do before do
create(:cluster, :provided_by_gcp, projects: [project]) create(:cluster, :provided_by_gcp, projects: [project])
project.team << [user, :master] project.add_master(user)
sign_in user sign_in user
end end
......
...@@ -12,7 +12,7 @@ describe 'Issue Boards add issue modal', :js do ...@@ -12,7 +12,7 @@ describe 'Issue Boards add issue modal', :js do
let!(:issue2) { create(:issue, project: project, title: 'hij', description: 'klm') } let!(:issue2) { create(:issue, project: project, title: 'hij', description: 'klm') }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
......
...@@ -11,8 +11,8 @@ describe 'Issue Boards', :js do ...@@ -11,8 +11,8 @@ describe 'Issue Boards', :js do
let!(:user2) { create(:user) } let!(:user2) { create(:user) }
before do before do
project.team << [user, :master] project.add_master(user)
project.team << [user2, :master] project.add_master(user2)
set_cookie('sidebar_collapsed', 'true') set_cookie('sidebar_collapsed', 'true')
...@@ -551,7 +551,7 @@ describe 'Issue Boards', :js do ...@@ -551,7 +551,7 @@ describe 'Issue Boards', :js do
let(:user_guest) { create(:user) } let(:user_guest) { create(:user) }
before do before do
project.team << [user_guest, :guest] project.add_guest(user_guest)
sign_out(:user) sign_out(:user)
sign_in(user_guest) sign_in(user_guest)
visit project_board_path(project, board) visit project_board_path(project, board)
......
...@@ -13,7 +13,7 @@ describe 'Issue Boards', :js do ...@@ -13,7 +13,7 @@ describe 'Issue Boards', :js do
let!(:issue3) { create(:labeled_issue, project: project, title: 'testing 3', labels: [label], relative_position: 1) } let!(:issue3) { create(:labeled_issue, project: project, title: 'testing 3', labels: [label], relative_position: 1) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -10,7 +10,7 @@ describe 'Issue Boards add issue modal filtering', :js do ...@@ -10,7 +10,7 @@ describe 'Issue Boards add issue modal filtering', :js do
let!(:issue1) { create(:issue, project: project) } let!(:issue1) { create(:issue, project: project) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
...@@ -76,7 +76,7 @@ describe 'Issue Boards add issue modal filtering', :js do ...@@ -76,7 +76,7 @@ describe 'Issue Boards add issue modal filtering', :js do
let!(:issue) { create(:issue, project: project, author: user2) } let!(:issue) { create(:issue, project: project, author: user2) }
before do before do
project.team << [user2, :developer] project.add_developer(user2)
visit_board visit_board
end end
...@@ -99,7 +99,7 @@ describe 'Issue Boards add issue modal filtering', :js do ...@@ -99,7 +99,7 @@ describe 'Issue Boards add issue modal filtering', :js do
let!(:issue) { create(:issue, project: project, assignees: [user2]) } let!(:issue) { create(:issue, project: project, assignees: [user2]) }
before do before do
project.team << [user2, :developer] project.add_developer(user2)
visit_board visit_board
end end
......
...@@ -8,7 +8,7 @@ describe 'Issue Boards new issue', :js do ...@@ -8,7 +8,7 @@ describe 'Issue Boards new issue', :js do
context 'authorized user' do context 'authorized user' do
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
......
...@@ -26,7 +26,7 @@ describe 'Commits' do ...@@ -26,7 +26,7 @@ describe 'Commits' do
let!(:status) { create(:generic_commit_status, pipeline: pipeline) } let!(:status) { create(:generic_commit_status, pipeline: pipeline) }
before do before do
project.team << [user, :reporter] project.add_reporter(user)
end end
describe 'Commit builds' do describe 'Commit builds' do
...@@ -51,7 +51,7 @@ describe 'Commits' do ...@@ -51,7 +51,7 @@ describe 'Commits' do
context 'when logged as developer' do context 'when logged as developer' do
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
describe 'Project commits' do describe 'Project commits' do
...@@ -145,7 +145,7 @@ describe 'Commits' do ...@@ -145,7 +145,7 @@ describe 'Commits' do
context "when logged as reporter" do context "when logged as reporter" do
before do before do
project.team << [user, :reporter] project.add_reporter(user)
build.update_attributes(legacy_artifacts_file: artifacts_file) build.update_attributes(legacy_artifacts_file: artifacts_file)
visit pipeline_path(pipeline) visit pipeline_path(pipeline)
end end
...@@ -188,7 +188,7 @@ describe 'Commits' do ...@@ -188,7 +188,7 @@ describe 'Commits' do
let(:branch_name) { 'master' } let(:branch_name) { 'master' }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
visit project_commits_path(project, branch_name) visit project_commits_path(project, branch_name)
end end
......
...@@ -95,7 +95,7 @@ feature 'Cycle Analytics', :js do ...@@ -95,7 +95,7 @@ feature 'Cycle Analytics', :js do
before do before do
user.update_attribute(:preferred_language, 'es') user.update_attribute(:preferred_language, 'es')
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
visit project_cycle_analytics_path(project) visit project_cycle_analytics_path(project)
wait_for_requests wait_for_requests
......
...@@ -6,8 +6,8 @@ RSpec.describe 'Dashboard Archived Project' do ...@@ -6,8 +6,8 @@ RSpec.describe 'Dashboard Archived Project' do
let(:archived_project) { create(:project, :archived) } let(:archived_project) { create(:project, :archived) }
before do before do
project.team << [user, :master] project.add_master(user)
archived_project.team << [user, :master] archived_project.add_master(user)
sign_in(user) sign_in(user)
......
...@@ -8,7 +8,7 @@ feature 'Tooltips on .timeago dates', :js do ...@@ -8,7 +8,7 @@ feature 'Tooltips on .timeago dates', :js do
context 'on the activity tab' do context 'on the activity tab' do
before do before do
project.team << [user, :master] project.add_master(user)
Event.create( project: project, author_id: user.id, action: Event::JOINED, Event.create( project: project, author_id: user.id, action: Event::JOINED,
updated_at: created_date, created_at: created_date) updated_at: created_date, created_at: created_date)
...@@ -27,7 +27,7 @@ feature 'Tooltips on .timeago dates', :js do ...@@ -27,7 +27,7 @@ feature 'Tooltips on .timeago dates', :js do
context 'on the snippets tab' do context 'on the snippets tab' do
before do before do
project.team << [user, :master] project.add_master(user)
create(:snippet, author: user, updated_at: created_date, created_at: created_date) create(:snippet, author: user, updated_at: created_date, created_at: created_date)
sign_in user sign_in user
......
...@@ -12,7 +12,7 @@ RSpec.describe 'Dashboard Issues' do ...@@ -12,7 +12,7 @@ RSpec.describe 'Dashboard Issues' do
let!(:other_issue) { create :issue, project: project } let!(:other_issue) { create :issue, project: project }
before do before do
[project, project_with_issues_disabled].each { |project| project.team << [current_user, :master] } [project, project_with_issues_disabled].each { |project| project.add_master(current_user) }
sign_in(current_user) sign_in(current_user)
visit issues_dashboard_path(assignee_id: current_user.id) visit issues_dashboard_path(assignee_id: current_user.id)
end end
......
...@@ -16,7 +16,7 @@ feature 'Dashboard > Milestones' do ...@@ -16,7 +16,7 @@ feature 'Dashboard > Milestones' do
let(:project) { create(:project, namespace: user.namespace) } let(:project) { create(:project, namespace: user.namespace) }
let!(:milestone) { create(:milestone, project: project) } let!(:milestone) { create(:milestone, project: project) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
visit dashboard_milestones_path visit dashboard_milestones_path
end end
......
...@@ -5,7 +5,7 @@ feature 'Project member activity', :js do ...@@ -5,7 +5,7 @@ feature 'Project member activity', :js do
let(:project) { create(:project, :public, name: 'x', namespace: user.namespace) } let(:project) { create(:project, :public, name: 'x', namespace: user.namespace) }
before do before do
project.team << [user, :master] project.add_master(user)
end end
def visit_activities_and_wait_with_event(event_type) def visit_activities_and_wait_with_event(event_type)
......
...@@ -6,7 +6,7 @@ feature 'Dashboard Projects' do ...@@ -6,7 +6,7 @@ feature 'Dashboard Projects' do
let(:project2) { create(:project, :public, name: 'Community project') } let(:project2) { create(:project, :public, name: 'Community project') }
before do before do
project.team << [user, :developer] project.add_developer(user)
sign_in(user) sign_in(user)
end end
......
...@@ -15,8 +15,8 @@ feature 'Dashboard > User filters todos', :js do ...@@ -15,8 +15,8 @@ feature 'Dashboard > User filters todos', :js do
create(:todo, user: user_1, author: user_2, project: project_1, target: issue, action: 1) create(:todo, user: user_1, author: user_2, project: project_1, target: issue, action: 1)
create(:todo, user: user_1, author: user_1, project: project_2, target: merge_request, action: 2) create(:todo, user: user_1, author: user_1, project: project_2, target: merge_request, action: 2)
project_1.team << [user_1, :developer] project_1.add_developer(user_1)
project_2.team << [user_1, :developer] project_2.add_developer(user_1)
sign_in(user_1) sign_in(user_1)
visit dashboard_todos_path visit dashboard_todos_path
end end
...@@ -66,8 +66,8 @@ feature 'Dashboard > User filters todos', :js do ...@@ -66,8 +66,8 @@ feature 'Dashboard > User filters todos', :js do
create(:todo, user: user_1, author: user_3, project: project_1, target: issue, action: 1, state: :done) create(:todo, user: user_1, author: user_3, project: project_1, target: issue, action: 1, state: :done)
create(:todo, user: user_1, author: user_4, project: project_2, target: merge_request, action: 2, state: :done) create(:todo, user: user_1, author: user_4, project: project_2, target: merge_request, action: 2, state: :done)
project_1.team << [user_3, :developer] project_1.add_developer(user_3)
project_2.team << [user_4, :developer] project_2.add_developer(user_4)
visit dashboard_todos_path(state: 'done') visit dashboard_todos_path(state: 'done')
......
...@@ -9,7 +9,7 @@ feature 'Dashboard > User sorts todos' do ...@@ -9,7 +9,7 @@ feature 'Dashboard > User sorts todos' do
let(:label_3) { create(:label, title: 'label_3', project: project, priority: 3) } let(:label_3) { create(:label, title: 'label_3', project: project, priority: 3) }
before do before do
project.team << [user, :developer] project.add_developer(user)
end end
context 'sort options' do context 'sort options' do
......
...@@ -7,14 +7,14 @@ describe 'Dashboard > User filters projects' do ...@@ -7,14 +7,14 @@ describe 'Dashboard > User filters projects' do
let(:project2) { create(:project, name: 'Treasure', namespace: user2.namespace) } let(:project2) { create(:project, name: 'Treasure', namespace: user2.namespace) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
describe 'filtering personal projects' do describe 'filtering personal projects' do
before do before do
project2.team << [user, :developer] project2.add_developer(user)
visit dashboard_projects_path visit dashboard_projects_path
end end
......
...@@ -5,7 +5,7 @@ feature 'Global search' do ...@@ -5,7 +5,7 @@ feature 'Global search' do
let(:project) { create(:project, namespace: user.namespace) } let(:project) { create(:project, namespace: user.namespace) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -11,7 +11,7 @@ describe 'Awards Emoji' do ...@@ -11,7 +11,7 @@ describe 'Awards Emoji' do
context 'authorized user' do context 'authorized user' do
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -11,7 +11,7 @@ feature 'Issues > Labels bulk assignment' do ...@@ -11,7 +11,7 @@ feature 'Issues > Labels bulk assignment' do
context 'as an allowed user', :js do context 'as an allowed user', :js do
before do before do
project.team << [user, :master] project.add_master(user)
sign_in user sign_in user
end end
......
...@@ -8,7 +8,7 @@ feature 'Resolving all open discussions in a merge request from an issue', :js d ...@@ -8,7 +8,7 @@ feature 'Resolving all open discussions in a merge request from an issue', :js d
describe 'as a user with access to the project' do describe 'as a user with access to the project' do
before do before do
project.team << [user, :master] project.add_master(user)
sign_in user sign_in user
visit project_merge_request_path(project, merge_request) visit project_merge_request_path(project, merge_request)
end end
...@@ -81,7 +81,7 @@ feature 'Resolving all open discussions in a merge request from an issue', :js d ...@@ -81,7 +81,7 @@ feature 'Resolving all open discussions in a merge request from an issue', :js d
describe 'as a reporter' do describe 'as a reporter' do
before do before do
project.team << [user, :reporter] project.add_reporter(user)
sign_in user sign_in user
visit new_project_issue_path(project, merge_request_to_resolve_discussions_of: merge_request.iid) visit new_project_issue_path(project, merge_request_to_resolve_discussions_of: merge_request.iid)
end end
......
...@@ -8,7 +8,7 @@ feature 'Resolve an open discussion in a merge request by creating an issue' do ...@@ -8,7 +8,7 @@ feature 'Resolve an open discussion in a merge request by creating an issue' do
describe 'As a user with access to the project' do describe 'As a user with access to the project' do
before do before do
project.team << [user, :master] project.add_master(user)
sign_in user sign_in user
visit project_merge_request_path(project, merge_request) visit project_merge_request_path(project, merge_request)
end end
...@@ -65,7 +65,7 @@ feature 'Resolve an open discussion in a merge request by creating an issue' do ...@@ -65,7 +65,7 @@ feature 'Resolve an open discussion in a merge request by creating an issue' do
describe 'as a reporter' do describe 'as a reporter' do
before do before do
project.team << [user, :reporter] project.add_reporter(user)
sign_in user sign_in user
visit new_project_issue_path(project, merge_request_to_resolve_discussions_of: merge_request.iid, visit new_project_issue_path(project, merge_request_to_resolve_discussions_of: merge_request.iid,
discussion_to_resolve: discussion.id) discussion_to_resolve: discussion.id)
......
...@@ -20,9 +20,9 @@ describe 'Dropdown assignee', :js do ...@@ -20,9 +20,9 @@ describe 'Dropdown assignee', :js do
end end
before do before do
project.team << [user, :master] project.add_master(user)
project.team << [user_john, :master] project.add_master(user_john)
project.team << [user_jacob, :master] project.add_master(user_jacob)
sign_in(user) sign_in(user)
create(:issue, project: project) create(:issue, project: project)
...@@ -222,7 +222,7 @@ describe 'Dropdown assignee', :js do ...@@ -222,7 +222,7 @@ describe 'Dropdown assignee', :js do
expect(initial_size).to be > 0 expect(initial_size).to be > 0
new_user = create(:user) new_user = create(:user)
project.team << [new_user, :master] project.add_master(new_user)
find('.filtered-search-box .clear-search').click find('.filtered-search-box .clear-search').click
filtered_search.set('assignee') filtered_search.set('assignee')
filtered_search.send_keys(':') filtered_search.send_keys(':')
......
...@@ -28,9 +28,9 @@ describe 'Dropdown author', :js do ...@@ -28,9 +28,9 @@ describe 'Dropdown author', :js do
end end
before do before do
project.team << [user, :master] project.add_master(user)
project.team << [user_john, :master] project.add_master(user_john)
project.team << [user_jacob, :master] project.add_master(user_jacob)
sign_in(user) sign_in(user)
create(:issue, project: project) create(:issue, project: project)
...@@ -195,7 +195,7 @@ describe 'Dropdown author', :js do ...@@ -195,7 +195,7 @@ describe 'Dropdown author', :js do
expect(initial_size).to be > 0 expect(initial_size).to be > 0
new_user = create(:user) new_user = create(:user)
project.team << [new_user, :master] project.add_master(new_user)
find('.filtered-search-box .clear-search').click find('.filtered-search-box .clear-search').click
filtered_search.set('author') filtered_search.set('author')
send_keys_to_filtered_search(':') send_keys_to_filtered_search(':')
......
...@@ -28,7 +28,7 @@ describe 'Dropdown emoji', :js do ...@@ -28,7 +28,7 @@ describe 'Dropdown emoji', :js do
end end
before do before do
project.team << [user, :master] project.add_master(user)
create_list(:award_emoji, 2, user: user, name: 'thumbsup') create_list(:award_emoji, 2, user: user, name: 'thumbsup')
create_list(:award_emoji, 1, user: user, name: 'thumbsdown') create_list(:award_emoji, 1, user: user, name: 'thumbsdown')
create_list(:award_emoji, 3, user: user, name: 'star') create_list(:award_emoji, 3, user: user, name: 'star')
......
...@@ -13,7 +13,7 @@ describe 'Dropdown hint', :js do ...@@ -13,7 +13,7 @@ describe 'Dropdown hint', :js do
end end
before do before do
project.team << [user, :master] project.add_master(user)
create(:issue, project: project) create(:issue, project: project)
end end
......
...@@ -29,7 +29,7 @@ describe 'Dropdown milestone', :js do ...@@ -29,7 +29,7 @@ describe 'Dropdown milestone', :js do
end end
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
create(:issue, project: project) create(:issue, project: project)
......
...@@ -8,7 +8,7 @@ describe 'Search bar', :js do ...@@ -8,7 +8,7 @@ describe 'Search bar', :js do
let(:filtered_search) { find('.filtered-search') } let(:filtered_search) { find('.filtered-search') }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
create(:issue, project: project) create(:issue, project: project)
......
...@@ -13,8 +13,8 @@ describe 'New/edit issue', :js do ...@@ -13,8 +13,8 @@ describe 'New/edit issue', :js do
let!(:issue) { create(:issue, project: project, assignees: [user], milestone: milestone) } let!(:issue) { create(:issue, project: project, assignees: [user], milestone: milestone) }
before do before do
project.team << [user, :master] project.add_master(user)
project.team << [user2, :master] project.add_master(user2)
sign_in(user) sign_in(user)
end end
......
...@@ -7,7 +7,7 @@ feature 'GFM autocomplete', :js do ...@@ -7,7 +7,7 @@ feature 'GFM autocomplete', :js do
let(:issue) { create(:issue, project: project) } let(:issue) { create(:issue, project: project) }
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
visit project_issue_path(project, issue) visit project_issue_path(project, issue)
......
...@@ -18,7 +18,7 @@ feature 'Issue Sidebar' do ...@@ -18,7 +18,7 @@ feature 'Issue Sidebar' do
let(:issue2) { create(:issue, project: project, author: user2) } let(:issue2) { create(:issue, project: project, author: user2) }
before do before do
project.team << [user, :developer] project.add_developer(user)
visit_issue(project, issue2) visit_issue(project, issue2)
find('.block.assignee .edit-link').click find('.block.assignee .edit-link').click
...@@ -78,7 +78,7 @@ feature 'Issue Sidebar' do ...@@ -78,7 +78,7 @@ feature 'Issue Sidebar' do
context 'as a allowed user' do context 'as a allowed user' do
before do before do
project.team << [user, :developer] project.add_developer(user)
visit_issue(project, issue) visit_issue(project, issue)
end end
...@@ -156,7 +156,7 @@ feature 'Issue Sidebar' do ...@@ -156,7 +156,7 @@ feature 'Issue Sidebar' do
context 'as a guest' do context 'as a guest' do
before do before do
project.team << [user, :guest] project.add_guest(user)
visit_issue(project, issue) visit_issue(project, issue)
end end
......
...@@ -13,7 +13,7 @@ feature 'issue move to another project' do ...@@ -13,7 +13,7 @@ feature 'issue move to another project' do
context 'user does not have permission to move issue' do context 'user does not have permission to move issue' do
background do background do
old_project.team << [user, :guest] old_project.add_guest(user)
visit issue_path(issue) visit issue_path(issue)
end end
...@@ -31,8 +31,8 @@ feature 'issue move to another project' do ...@@ -31,8 +31,8 @@ feature 'issue move to another project' do
let(:cross_reference) { old_project.to_reference(new_project) } let(:cross_reference) { old_project.to_reference(new_project) }
background do background do
old_project.team << [user, :reporter] old_project.add_reporter(user)
new_project.team << [user, :reporter] new_project.add_reporter(user)
visit issue_path(issue) visit issue_path(issue)
end end
...@@ -50,7 +50,7 @@ feature 'issue move to another project' do ...@@ -50,7 +50,7 @@ feature 'issue move to another project' do
end end
scenario 'searching project dropdown', :js do scenario 'searching project dropdown', :js do
new_project_search.team << [user, :reporter] new_project_search.add_reporter(user)
find('.js-move-issue').click find('.js-move-issue').click
wait_for_requests wait_for_requests
...@@ -66,7 +66,7 @@ feature 'issue move to another project' do ...@@ -66,7 +66,7 @@ feature 'issue move to another project' do
context 'user does not have permission to move the issue to a project', :js do context 'user does not have permission to move the issue to a project', :js do
let!(:private_project) { create(:project, :private) } let!(:private_project) { create(:project, :private) }
let(:another_project) { create(:project) } let(:another_project) { create(:project) }
background { another_project.team << [user, :guest] } background { another_project.add_guest(user) }
scenario 'browsing projects in projects select' do scenario 'browsing projects in projects select' do
find('.js-move-issue').click find('.js-move-issue').click
......
...@@ -8,7 +8,7 @@ describe 'Create notes on issues', :js do ...@@ -8,7 +8,7 @@ describe 'Create notes on issues', :js do
let(:note_text) { "Check #{mention.to_reference}" } let(:note_text) { "Check #{mention.to_reference}" }
before do before do
project.team << [user, :developer] project.add_developer(user)
sign_in(user) sign_in(user)
visit project_issue_path(project, issue) visit project_issue_path(project, issue)
......
...@@ -17,7 +17,7 @@ describe 'New issue', :js do ...@@ -17,7 +17,7 @@ describe 'New issue', :js do
recaptcha_private_key: 'test private key' recaptcha_private_key: 'test private key'
) )
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
...@@ -6,7 +6,7 @@ feature 'Manually create a todo item from issue', :js do ...@@ -6,7 +6,7 @@ feature 'Manually create a todo item from issue', :js do
let!(:user) { create(:user)} let!(:user) { create(:user)}
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
visit project_issue_path(project, issue) visit project_issue_path(project, issue)
end end
......
...@@ -6,7 +6,7 @@ feature 'Multiple issue updating from issues#index', :js do ...@@ -6,7 +6,7 @@ feature 'Multiple issue updating from issues#index', :js do
let!(:user) { create(:user)} let!(:user) { create(:user)}
before do before do
project.team << [user, :master] project.add_master(user)
sign_in(user) sign_in(user)
end end
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment