Commit 9e9ab32b authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Resolve conflicts after merging CE to EE

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent b3ec93e2
...@@ -206,36 +206,7 @@ rake config_lint: *exec ...@@ -206,36 +206,7 @@ rake config_lint: *exec
rake brakeman: *exec rake brakeman: *exec
rake flay: *exec rake flay: *exec
license_finder: *exec license_finder: *exec
<<<<<<< HEAD
rake downtime_check: *exec rake downtime_check: *exec
=======
rake downtime_check:
<<: *exec
except:
- master
- tags
- /^[\d-]+-stable(-ee)?$/
rake ee_compat_check:
<<: *exec
only:
- branches@gitlab-org/gitlab-ce
except:
- master
- tags
- /^[\d-]+-stable(-ee)?$/
allow_failure: yes
cache:
key: "ee_compat_check_repo"
paths:
- ee_compat_check/ee-repo/
artifacts:
name: "${CI_JOB_NAME}_${CI_COMIT_REF_NAME}_${CI_COMMIT_SHA}"
when: on_failure
expire_in: 10d
paths:
- ee_compat_check/patches/*.patch
>>>>>>> ce-com/master
rake db:migrate:reset: rake db:migrate:reset:
stage: test stage: test
......
...@@ -139,10 +139,7 @@ entry. ...@@ -139,10 +139,7 @@ entry.
- Fix API group/issues default state filter. (Alexander Randa) - Fix API group/issues default state filter. (Alexander Randa)
- Prevent builds dropdown to close when the user clicks in a build. - Prevent builds dropdown to close when the user clicks in a build.
- Display all closed issues in “done” board list. - Display all closed issues in “done” board list.
<<<<<<< HEAD
- added focus mode button to issue boards. - added focus mode button to issue boards.
=======
>>>>>>> ce-com/master
- Remove no-new annotation from file_template_mediator.js. - Remove no-new annotation from file_template_mediator.js.
- Changed dropdown style slightly. - Changed dropdown style slightly.
- Change gfm textarea to use monospace font. - Change gfm textarea to use monospace font.
......
...@@ -441,7 +441,6 @@ export default { ...@@ -441,7 +441,6 @@ export default {
<template> <template>
<tr :class="{ 'js-child-row': model.isChildren }"> <tr :class="{ 'js-child-row': model.isChildren }">
<td> <td>
<<<<<<< HEAD:app/assets/javascripts/environments/components/environment_item.vue
<span <span
class="deploy-board-icon" class="deploy-board-icon"
v-if="model.hasDeployBoard" v-if="model.hasDeployBoard"
...@@ -458,8 +457,6 @@ export default { ...@@ -458,8 +457,6 @@ export default {
aria-hidden="true" /> aria-hidden="true" />
</span> </span>
=======
>>>>>>> ce-com/master:app/assets/javascripts/environments/components/environment_item.vue
<a <a
v-if="!model.isFolder" v-if="!model.isFolder"
class="environment-name" class="environment-name"
......
...@@ -3,18 +3,12 @@ ...@@ -3,18 +3,12 @@
* Render environments table. * Render environments table.
*/ */
import EnvironmentTableRowComponent from './environment_item.vue'; import EnvironmentTableRowComponent from './environment_item.vue';
<<<<<<< HEAD
import DeployBoard from './deploy_board_component'; import DeployBoard from './deploy_board_component';
=======
>>>>>>> ce-com/master
export default { export default {
components: { components: {
'environment-item': EnvironmentTableRowComponent, 'environment-item': EnvironmentTableRowComponent,
<<<<<<< HEAD
DeployBoard, DeployBoard,
=======
>>>>>>> ce-com/master
}, },
props: { props: {
...@@ -46,7 +40,6 @@ export default { ...@@ -46,7 +40,6 @@ export default {
required: false, required: false,
default: false, default: false,
}, },
<<<<<<< HEAD
toggleDeployBoard: { toggleDeployBoard: {
type: Function, type: Function,
...@@ -59,8 +52,6 @@ export default { ...@@ -59,8 +52,6 @@ export default {
required: false, required: false,
default: () => ({}), default: () => ({}),
}, },
=======
>>>>>>> ce-com/master
}, },
methods: { methods: {
...@@ -101,7 +92,6 @@ export default { ...@@ -101,7 +92,6 @@ export default {
:model="model" :model="model"
:can-create-deployment="canCreateDeployment" :can-create-deployment="canCreateDeployment"
:can-read-environment="canReadEnvironment" :can-read-environment="canReadEnvironment"
<<<<<<< HEAD
:service="service" :service="service"
:toggleDeployBoard="toggleDeployBoard" :toggleDeployBoard="toggleDeployBoard"
/> />
...@@ -117,9 +107,6 @@ export default { ...@@ -117,9 +107,6 @@ export default {
/> />
</td> </td>
</tr> </tr>
=======
:service="service" />
>>>>>>> ce-com/master
<template v-if="model.isFolder && model.isOpen && model.children && model.children.length > 0"> <template v-if="model.isFolder && model.isOpen && model.children && model.children.length > 0">
<tr v-if="isLoadingFolderContent"> <tr v-if="isLoadingFolderContent">
......
...@@ -53,11 +53,8 @@ module MembershipActions ...@@ -53,11 +53,8 @@ module MembershipActions
"You left the \"#{membershipable.human_name}\" #{source_type}." "You left the \"#{membershipable.human_name}\" #{source_type}."
end end
<<<<<<< HEAD
log_audit_event(member, action: :destroy) unless member.request? log_audit_event(member, action: :destroy) unless member.request?
=======
>>>>>>> ce-com/master
redirect_path = member.request? ? member.source : [:dashboard, membershipable.class.to_s.tableize] redirect_path = member.request? ? member.source : [:dashboard, membershipable.class.to_s.tableize]
redirect_to redirect_path, notice: notice redirect_to redirect_path, notice: notice
...@@ -69,11 +66,11 @@ module MembershipActions ...@@ -69,11 +66,11 @@ module MembershipActions
raise NotImplementedError raise NotImplementedError
end end
<<<<<<< HEAD
def log_audit_event(member, options = {}) def log_audit_event(member, options = {})
AuditEventService.new(current_user, membershipable, options) AuditEventService.new(current_user, membershipable, options)
.for_member(member).security_event .for_member(member).security_event
======= end
def members_page_url def members_page_url
if membershipable.is_a?(Project) if membershipable.is_a?(Project)
project_settings_members_path(membershipable) project_settings_members_path(membershipable)
...@@ -84,6 +81,5 @@ module MembershipActions ...@@ -84,6 +81,5 @@ module MembershipActions
def source_type def source_type
@source_type ||= membershipable.class.to_s.humanize(capitalize: false) @source_type ||= membershipable.class.to_s.humanize(capitalize: false)
>>>>>>> ce-com/master
end end
end end
...@@ -24,30 +24,6 @@ class Groups::GroupMembersController < Groups::ApplicationController ...@@ -24,30 +24,6 @@ class Groups::GroupMembersController < Groups::ApplicationController
@group_member = @group.group_members.new @group_member = @group.group_members.new
end end
<<<<<<< HEAD
def create
if params[:user_ids].blank?
return redirect_to(group_group_members_path(@group), alert: 'No users specified.')
end
@group.add_users(
params[:user_ids].split(','),
params[:access_level],
current_user: current_user,
expires_at: params[:expires_at]
)
group_members = @group.group_members.where(user_id: params[:user_ids].split(','))
group_members.each do |group_member|
log_audit_event(group_member, action: :create)
end
redirect_to group_group_members_path(@group), notice: 'Users were successfully added.'
end
=======
>>>>>>> ce-com/master
def update def update
@group_member = @group.group_members.find(params[:id]) @group_member = @group.group_members.find(params[:id])
...@@ -60,20 +36,6 @@ class Groups::GroupMembersController < Groups::ApplicationController ...@@ -60,20 +36,6 @@ class Groups::GroupMembersController < Groups::ApplicationController
end end
end end
<<<<<<< HEAD
def destroy
member = Members::DestroyService.new(@group, current_user, id: params[:id]).execute(:all)
log_audit_event(member, action: :destroy)
respond_to do |format|
format.html { redirect_to group_group_members_path(@group), notice: 'User was successfully removed from group.' }
format.js { head :ok }
end
end
=======
>>>>>>> ce-com/master
def resend_invite def resend_invite
redirect_path = group_group_members_path(@group) redirect_path = group_group_members_path(@group)
......
...@@ -10,27 +10,6 @@ class Projects::ProjectMembersController < Projects::ApplicationController ...@@ -10,27 +10,6 @@ class Projects::ProjectMembersController < Projects::ApplicationController
redirect_to namespace_project_settings_members_path(@project.namespace, @project, sort: sort) redirect_to namespace_project_settings_members_path(@project.namespace, @project, sort: sort)
end end
<<<<<<< HEAD
def create
status = Members::CreateService.new(@project, current_user, params).execute
redirect_url = namespace_project_settings_members_path(@project.namespace, @project)
if status
members = @project.project_members.where(user_id: params[:user_ids].split(','))
members.each do |member|
log_audit_event(member, action: :create)
end
redirect_to redirect_url, notice: 'Users were successfully added.'
else
redirect_to redirect_url, alert: 'No users or groups specified.'
end
end
=======
>>>>>>> ce-com/master
def update def update
@project_member = @project.project_members.find(params[:id]) @project_member = @project.project_members.find(params[:id])
...@@ -43,23 +22,6 @@ class Projects::ProjectMembersController < Projects::ApplicationController ...@@ -43,23 +22,6 @@ class Projects::ProjectMembersController < Projects::ApplicationController
end end
end end
<<<<<<< HEAD
def destroy
member = Members::DestroyService.new(@project, current_user, params).
execute(:all)
log_audit_event(member, action: :destroy)
respond_to do |format|
format.html do
redirect_to namespace_project_settings_members_path(@project.namespace, @project)
end
format.js { head :ok }
end
end
=======
>>>>>>> ce-com/master
def resend_invite def resend_invite
redirect_path = namespace_project_settings_members_path(@project.namespace, @project) redirect_path = namespace_project_settings_members_path(@project.namespace, @project)
......
...@@ -162,7 +162,6 @@ module IssuablesHelper ...@@ -162,7 +162,6 @@ module IssuablesHelper
html.html_safe html.html_safe
end end
<<<<<<< HEAD
def cached_issuables_count_for_state(issuable_type, state) def cached_issuables_count_for_state(issuable_type, state)
Rails.cache.fetch(issuables_state_counter_cache_key(issuable_type, state), expires_in: 2.minutes) do Rails.cache.fetch(issuables_state_counter_cache_key(issuable_type, state), expires_in: 2.minutes) do
issuables_count_for_state(issuable_type, state) issuables_count_for_state(issuable_type, state)
...@@ -174,10 +173,10 @@ module IssuablesHelper ...@@ -174,10 +173,10 @@ module IssuablesHelper
Rails.cache.fetch(cache_key, expires_in: 2.minutes) do Rails.cache.fetch(cache_key, expires_in: 2.minutes) do
assigned_issuables_count(assignee, issuable_type, state) assigned_issuables_count(assignee, issuable_type, state)
end end
======= end
def assigned_issuables_count(issuable_type) def assigned_issuables_count(issuable_type)
current_user.public_send("assigned_open_#{issuable_type}_count") current_user.public_send("assigned_open_#{issuable_type}_count")
>>>>>>> ce-com/master
end end
def issuable_filter_params def issuable_filter_params
......
...@@ -50,15 +50,10 @@ class ProjectTeam ...@@ -50,15 +50,10 @@ class ProjectTeam
end end
def add_users(users, access_level, current_user: nil, expires_at: nil) def add_users(users, access_level, current_user: nil, expires_at: nil)
<<<<<<< HEAD
return false if group_member_lock return false if group_member_lock
ProjectMember.add_users_to_projects(
[project.id],
=======
ProjectMember.add_users( ProjectMember.add_users(
project, project,
>>>>>>> ce-com/master
users, users,
access_level, access_level,
current_user: current_user, current_user: current_user,
......
...@@ -9,13 +9,18 @@ module Members ...@@ -9,13 +9,18 @@ module Members
def execute def execute
return false if params[:user_ids].blank? return false if params[:user_ids].blank?
@source.add_users( members = @source.add_users(
params[:user_ids].split(','), params[:user_ids].split(','),
params[:access_level], params[:access_level],
expires_at: params[:expires_at], expires_at: params[:expires_at],
current_user: current_user current_user: current_user
) )
members.compact.each do |member|
AuditEventService.new(@current_user, @source, action: :create)
.for_member(member).security_event
end
true true
end end
end end
......
...@@ -20,6 +20,9 @@ module Members ...@@ -20,6 +20,9 @@ module Members
raise Gitlab::Access::AccessDeniedError unless can_destroy_member?(member) raise Gitlab::Access::AccessDeniedError unless can_destroy_member?(member)
AuthorizedDestroyService.new(member, current_user).execute AuthorizedDestroyService.new(member, current_user).execute
AuditEventService.new(@current_user, @source, action: :destroy)
.for_member(member).security_event
end end
private private
......
...@@ -123,7 +123,6 @@ ActiveRecord::Schema.define(version: 20170421113144) do ...@@ -123,7 +123,6 @@ ActiveRecord::Schema.define(version: 20170421113144) do
t.integer "unique_ips_limit_per_user" t.integer "unique_ips_limit_per_user"
t.integer "unique_ips_limit_time_window" t.integer "unique_ips_limit_time_window"
t.boolean "unique_ips_limit_enabled", default: false, null: false t.boolean "unique_ips_limit_enabled", default: false, null: false
<<<<<<< HEAD
t.integer "minimum_mirror_sync_time", default: 15, null: false t.integer "minimum_mirror_sync_time", default: 15, null: false
t.string "default_artifacts_expire_in", default: "0", null: false t.string "default_artifacts_expire_in", default: "0", null: false
t.string "elasticsearch_url", default: "http://localhost:9200" t.string "elasticsearch_url", default: "http://localhost:9200"
...@@ -132,14 +131,10 @@ ActiveRecord::Schema.define(version: 20170421113144) do ...@@ -132,14 +131,10 @@ ActiveRecord::Schema.define(version: 20170421113144) do
t.string "elasticsearch_aws_access_key" t.string "elasticsearch_aws_access_key"
t.string "elasticsearch_aws_secret_access_key" t.string "elasticsearch_aws_secret_access_key"
t.integer "geo_status_timeout", default: 10 t.integer "geo_status_timeout", default: 10
=======
t.decimal "polling_interval_multiplier", default: 1.0, null: false
t.integer "cached_markdown_version"
t.boolean "usage_ping_enabled", default: true, null: false
>>>>>>> ce-com/master
t.string "uuid" t.string "uuid"
t.decimal "polling_interval_multiplier", default: 1.0, null: false t.decimal "polling_interval_multiplier", default: 1.0, null: false
t.boolean "elasticsearch_experimental_indexer" t.boolean "elasticsearch_experimental_indexer"
t.integer "cached_markdown_version"
end end
create_table "approvals", force: :cascade do |t| create_table "approvals", force: :cascade do |t|
...@@ -575,11 +570,8 @@ ActiveRecord::Schema.define(version: 20170421113144) do ...@@ -575,11 +570,8 @@ ActiveRecord::Schema.define(version: 20170421113144) do
t.integer "time_estimate" t.integer "time_estimate"
t.integer "relative_position" t.integer "relative_position"
t.datetime "closed_at" t.datetime "closed_at"
<<<<<<< HEAD
t.string "service_desk_reply_to" t.string "service_desk_reply_to"
=======
t.integer "cached_markdown_version" t.integer "cached_markdown_version"
>>>>>>> ce-com/master
end end
add_index "issues", ["assignee_id"], name: "index_issues_on_assignee_id", using: :btree add_index "issues", ["assignee_id"], name: "index_issues_on_assignee_id", using: :btree
...@@ -784,11 +776,8 @@ ActiveRecord::Schema.define(version: 20170421113144) do ...@@ -784,11 +776,8 @@ ActiveRecord::Schema.define(version: 20170421113144) do
t.text "title_html" t.text "title_html"
t.text "description_html" t.text "description_html"
t.integer "time_estimate" t.integer "time_estimate"
<<<<<<< HEAD
t.boolean "squash", default: false, null: false t.boolean "squash", default: false, null: false
=======
t.integer "cached_markdown_version" t.integer "cached_markdown_version"
>>>>>>> ce-com/master
end end
add_index "merge_requests", ["assignee_id"], name: "index_merge_requests_on_assignee_id", using: :btree add_index "merge_requests", ["assignee_id"], name: "index_merge_requests_on_assignee_id", using: :btree
...@@ -865,14 +854,11 @@ ActiveRecord::Schema.define(version: 20170421113144) do ...@@ -865,14 +854,11 @@ ActiveRecord::Schema.define(version: 20170421113144) do
t.text "description_html" t.text "description_html"
t.boolean "lfs_enabled" t.boolean "lfs_enabled"
t.integer "parent_id" t.integer "parent_id"
t.boolean "require_two_factor_authentication", default: false, null: false
t.integer "two_factor_grace_period", default: 48, null: false
<<<<<<< HEAD
t.integer "shared_runners_minutes_limit" t.integer "shared_runners_minutes_limit"
t.integer "repository_size_limit", limit: 8 t.integer "repository_size_limit", limit: 8
======= t.boolean "require_two_factor_authentication", default: false, null: false
t.integer "two_factor_grace_period", default: 48, null: false
t.integer "cached_markdown_version" t.integer "cached_markdown_version"
>>>>>>> ce-com/master
end end
add_index "namespaces", ["created_at"], name: "index_namespaces_on_created_at", using: :btree add_index "namespaces", ["created_at"], name: "index_namespaces_on_created_at", using: :btree
...@@ -1129,16 +1115,13 @@ ActiveRecord::Schema.define(version: 20170421113144) do ...@@ -1129,16 +1115,13 @@ ActiveRecord::Schema.define(version: 20170421113144) do
t.boolean "lfs_enabled" t.boolean "lfs_enabled"
t.text "description_html" t.text "description_html"
t.boolean "only_allow_merge_if_all_discussions_are_resolved" t.boolean "only_allow_merge_if_all_discussions_are_resolved"
t.integer "auto_cancel_pending_pipelines", default: 0, null: false
t.integer "repository_size_limit", limit: 8 t.integer "repository_size_limit", limit: 8
t.integer "sync_time", default: 60, null: false t.integer "sync_time", default: 60, null: false
t.boolean "printing_merge_request_link_enabled", default: true, null: false t.boolean "printing_merge_request_link_enabled", default: true, null: false
t.string "import_jid" t.integer "auto_cancel_pending_pipelines", default: 0, null: false
<<<<<<< HEAD
t.boolean "service_desk_enabled" t.boolean "service_desk_enabled"
======= t.string "import_jid"
t.integer "cached_markdown_version" t.integer "cached_markdown_version"
>>>>>>> ce-com/master
end end
add_index "projects", ["ci_id"], name: "index_projects_on_ci_id", using: :btree add_index "projects", ["ci_id"], name: "index_projects_on_ci_id", using: :btree
...@@ -1538,11 +1521,11 @@ ActiveRecord::Schema.define(version: 20170421113144) do ...@@ -1538,11 +1521,11 @@ ActiveRecord::Schema.define(version: 20170421113144) do
t.string "organization" t.string "organization"
t.boolean "authorized_projects_populated" t.boolean "authorized_projects_populated"
t.boolean "auditor", default: false, null: false t.boolean "auditor", default: false, null: false
t.boolean "require_two_factor_authentication_from_group", default: false, null: false
t.integer "two_factor_grace_period", default: 48, null: false
t.boolean "ghost" t.boolean "ghost"
t.date "last_activity_on" t.date "last_activity_on"
t.boolean "notified_of_own_activity" t.boolean "notified_of_own_activity"
t.boolean "require_two_factor_authentication_from_group", default: false, null: false
t.integer "two_factor_grace_period", default: 48, null: false
t.boolean "support_bot" t.boolean "support_bot"
end end
......
...@@ -157,14 +157,13 @@ module Banzai ...@@ -157,14 +157,13 @@ module Banzai
Rails.cache.send(:expanded_key, full_cache_key(cache_key, pipeline_name)) Rails.cache.send(:expanded_key, full_cache_key(cache_key, pipeline_name))
end end
<<<<<<< HEAD
def update_object(object, html_field, html) def update_object(object, html_field, html)
object.update_column(html_field, html) unless Gitlab::Geo.secondary? object.update_column(html_field, html) unless Gitlab::Geo.secondary?
======= end
# GitLab EE needs to disable updates on GET requests in Geo # GitLab EE needs to disable updates on GET requests in Geo
def self.update_object?(object) def self.update_object?(object)
true true
>>>>>>> ce-com/master
end end
end end
end end
...@@ -13,15 +13,13 @@ feature 'Groups > Audit Events', js: true, feature: true do ...@@ -13,15 +13,13 @@ feature 'Groups > Audit Events', js: true, feature: true do
describe 'changing a user access level' do describe 'changing a user access level' do
it "appears in the group's audit events" do it "appears in the group's audit events" do
visit group_path(group) visit group_group_members_path(group)
click_link 'Members'
group_member = group.members.find_by(user_id: pete) group_member = group.members.find_by(user_id: pete)
page.within "#group_member_#{group_member.id}" do page.within "#group_member_#{group_member.id}" do
click_button 'Edit access level' click_button('Developer')
select 'Master', from: 'group_member_access_level' click_link('Master')
click_button 'Save'
end end
# This is to avoid a Capybara::Poltergeist::MouseEventFailed error # This is to avoid a Capybara::Poltergeist::MouseEventFailed error
......
...@@ -38,15 +38,13 @@ feature 'Projects > Audit Events', js: true, feature: true do ...@@ -38,15 +38,13 @@ feature 'Projects > Audit Events', js: true, feature: true do
end end
it "appears in the project's audit events" do it "appears in the project's audit events" do
visit namespace_project_path(project.namespace, project) visit namespace_project_settings_members_path(project.namespace, project)
click_link 'Members'
project_member = project.project_member(pete) project_member = project.project_member(pete)
page.within "#project_member_#{project_member.id}" do page.within "#project_member_#{project_member.id}" do
click_button 'Edit access level' click_button('Developer')
select 'Master', from: 'project_member_access_level' click_link('Reporter')
click_button 'Save'
end end
# This is to avoid a Capybara::Poltergeist::MouseEventFailed error # This is to avoid a Capybara::Poltergeist::MouseEventFailed error
......
...@@ -14,7 +14,6 @@ describe Banzai::Renderer do ...@@ -14,7 +14,6 @@ describe Banzai::Renderer do
let(:renderer) { Banzai::Renderer } let(:renderer) { Banzai::Renderer }
subject { renderer.render_field(object, :field) } subject { renderer.render_field(object, :field) }
<<<<<<< HEAD
context "with an empty cache" do context "with an empty cache" do
let(:object) { fake_object(:markdown) } let(:object) { fake_object(:markdown) }
it "caches and returns the result" do it "caches and returns the result" do
...@@ -30,10 +29,9 @@ describe Banzai::Renderer do ...@@ -30,10 +29,9 @@ describe Banzai::Renderer do
expect(subject).to eq(:html) expect(subject).to eq(:html)
end end
end end
=======
context 'with a stale cache' do context 'with a stale cache' do
let(:object) { fake_object(fresh: false) } let(:object) { fake_object(fresh: false) }
>>>>>>> ce-com/master
it 'caches and returns the result' do it 'caches and returns the result' do
expect(object).to receive(:refresh_markdown_cache!).with(do_update: true) expect(object).to receive(:refresh_markdown_cache!).with(do_update: true)
......
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