All conflicts resolved

parent 09dc46e5
...@@ -891,13 +891,9 @@ DEPENDENCIES ...@@ -891,13 +891,9 @@ DEPENDENCIES
gollum-lib (~> 4.2) gollum-lib (~> 4.2)
gollum-rugged_adapter (~> 0.4.2) gollum-rugged_adapter (~> 0.4.2)
gon (~> 6.1.0) gon (~> 6.1.0)
<<<<<<< HEAD
grape (~> 0.15.0)
gssapi
=======
grape (~> 0.18.0) grape (~> 0.18.0)
>>>>>>> ce/master
grape-entity (~> 0.6.0) grape-entity (~> 0.6.0)
gssapi
haml_lint (~> 0.18.2) haml_lint (~> 0.18.2)
hamlit (~> 2.6.1) hamlit (~> 2.6.1)
health_check (~> 2.2.0) health_check (~> 2.2.0)
......
<<<<<<< HEAD
/* eslint-disable */
=======
/* eslint-disable func-names, comma-dangle, new-cap, no-new */ /* eslint-disable func-names, comma-dangle, new-cap, no-new */
/* global Vue */ /* global Vue */
/* global ResolveCount */ /* global ResolveCount */
//= require vue
//= require vue-resource
>>>>>>> ce/master
//= require_directory ./models //= require_directory ./models
//= require_directory ./stores //= require_directory ./stores
//= require_directory ./services //= require_directory ./services
......
...@@ -119,7 +119,6 @@ ...@@ -119,7 +119,6 @@
}); });
}; };
<<<<<<< HEAD
MergeRequestWidget.prototype.rebaseInProgress = function() { MergeRequestWidget.prototype.rebaseInProgress = function() {
return $.ajax({ return $.ajax({
type: 'GET', type: 'GET',
...@@ -135,11 +134,11 @@ ...@@ -135,11 +134,11 @@
})(this), })(this),
dataType: 'json' dataType: 'json'
}); });
======= };
MergeRequestWidget.prototype.cancelPolling = function () { MergeRequestWidget.prototype.cancelPolling = function () {
this.ciStatusInterval.cancel(); this.ciStatusInterval.cancel();
this.ciEnvironmentStatusInterval.cancel(); this.ciEnvironmentStatusInterval.cancel();
>>>>>>> ce/master
}; };
MergeRequestWidget.prototype.getMergeStatus = function() { MergeRequestWidget.prototype.getMergeStatus = function() {
......
<<<<<<< HEAD
/* eslint-disable */ /* eslint-disable */
(global => { (global => {
global.gl = global.gl || {}; global.gl = global.gl || {};
=======
/* eslint-disable comma-dangle, no-unused-vars */
class ProtectedBranchDropdown {
constructor(options) {
this.onSelect = options.onSelect;
this.$dropdown = options.$dropdown;
this.$dropdownContainer = this.$dropdown.parent();
this.$dropdownFooter = this.$dropdownContainer.find('.dropdown-footer');
this.$protectedBranch = this.$dropdownContainer.find('.create-new-protected-branch');
>>>>>>> ce/master
class ProtectedBranchDropdown { class ProtectedBranchDropdown {
constructor(options) { constructor(options) {
......
/* eslint-disable no-new, arrow-parens, no-param-reassign, no-irregular-whitespace, padded-blocks, comma-dangle, no-trailing-spaces, semi, max-len */ /* eslint-disable */
/* global Flash */ /* global Flash */
(global => { (global => {
global.gl = global.gl || {}; global.gl = global.gl || {};
const ACCESS_LEVELS = { const ACCESS_LEVELS = {
MERGE: 'merge_access_levels', MERGE: 'merge_access_levels',
...@@ -30,7 +30,6 @@ ...@@ -30,7 +30,6 @@
} }
buildDropdowns() { buildDropdowns() {
// Allowed to merge dropdown // Allowed to merge dropdown
this['merge_access_levels_dropdown'] = new gl.ProtectedBranchAccessDropdown({ this['merge_access_levels_dropdown'] = new gl.ProtectedBranchAccessDropdown({
accessLevel: ACCESS_LEVELS.MERGE, accessLevel: ACCESS_LEVELS.MERGE,
...@@ -54,7 +53,7 @@ ...@@ -54,7 +53,7 @@
this.hasChanges = true; this.hasChanges = true;
} }
<<<<<<< HEAD
onDropdownHide() { onDropdownHide() {
if (!this.hasChanges) return; if (!this.hasChanges) return;
...@@ -62,10 +61,6 @@ ...@@ -62,10 +61,6 @@
this.updatePermissions(); this.updatePermissions();
} }
=======
// Do not update if one dropdown has not selected any option
if (!($allowedToMergeInput.length && $allowedToPushInput.length)) return;
>>>>>>> ce/master
updatePermissions() { updatePermissions() {
let formData = {}; let formData = {};
......
...@@ -84,14 +84,6 @@ $warning-message-border: #f0e2bb; ...@@ -84,14 +84,6 @@ $warning-message-border: #f0e2bb;
*/ */
$border-color: #e5e5e5; $border-color: #e5e5e5;
$focus-border-color: #3aabf0; $focus-border-color: #3aabf0;
<<<<<<< HEAD
$table-border-color: #f0f0f0;
$background-color: $gray-light;
$dark-background-color: #f5f5f5;
$table-text-gray: #8f8f8f;
$sidebar-collapsed-icon-color: #999;
=======
>>>>>>> ce/master
$well-expand-item: #e8f2f7; $well-expand-item: #e8f2f7;
$well-inner-border: #eef0f2; $well-inner-border: #eef0f2;
$well-light-border: #f1f1f1; $well-light-border: #f1f1f1;
...@@ -190,12 +182,9 @@ $count-arrow-border: #dce0e5; ...@@ -190,12 +182,9 @@ $count-arrow-border: #dce0e5;
$save-project-loader-color: #555; $save-project-loader-color: #555;
$divergence-graph-bar-bg: #ccc; $divergence-graph-bar-bg: #ccc;
$divergence-graph-separator-bg: #ccc; $divergence-graph-separator-bg: #ccc;
<<<<<<< HEAD
$issue-box-upcoming-bg: #8f8f8f; $issue-box-upcoming-bg: #8f8f8f;
$pages-group-name-color: #4c4e54; $pages-group-name-color: #4c4e54;
$ldap-members-override-bg: #fff1e0; $ldap-members-override-bg: #fff1e0;
=======
>>>>>>> ce/master
/* /*
* Common component specific colors * Common component specific colors
......
...@@ -6,11 +6,7 @@ module OauthApplications ...@@ -6,11 +6,7 @@ module OauthApplications
end end
def prepare_scopes def prepare_scopes
<<<<<<< HEAD
scopes = params.dig(:doorkeeper_application, :scopes)
=======
scopes = params.fetch(:doorkeeper_application, {}).fetch(:scopes, nil) scopes = params.fetch(:doorkeeper_application, {}).fetch(:scopes, nil)
>>>>>>> ce/master
if scopes if scopes
params[:doorkeeper_application][:scopes] = scopes.join(' ') params[:doorkeeper_application][:scopes] = scopes.join(' ')
......
...@@ -18,15 +18,11 @@ module ServiceParams ...@@ -18,15 +18,11 @@ module ServiceParams
:add_pusher, :send_from_committer_email, :disable_diffs, :add_pusher, :send_from_committer_email, :disable_diffs,
:external_wiki_url, :notify, :color, :external_wiki_url, :notify, :color,
:server_host, :server_port, :default_irc_uri, :enable_ssl_verification, :server_host, :server_port, :default_irc_uri, :enable_ssl_verification,
<<<<<<< HEAD :jira_issue_transition_id, :url, :project_key, :ca_pem, :namespace,
:jira_issue_transition_id, :url, :project_key,
## EE Specific ## EE Specific
:multiproject_enabled, :pass_unstable, :multiproject_enabled, :pass_unstable,
:jenkins_url, :project_name] :jenkins_url, :project_name]
=======
:jira_issue_transition_id, :url, :project_key, :ca_pem, :namespace]
>>>>>>> ce/master
# Parameters to ignore if no value is specified # Parameters to ignore if no value is specified
FILTER_BLANK_PARAMS = [:password] FILTER_BLANK_PARAMS = [:password]
......
...@@ -414,7 +414,6 @@ module ProjectsHelper ...@@ -414,7 +414,6 @@ module ProjectsHelper
end end
end end
<<<<<<< HEAD
def membership_locked? def membership_locked?
if @project.group && @project.group.membership_lock if @project.group && @project.group.membership_lock
true true
...@@ -423,8 +422,6 @@ module ProjectsHelper ...@@ -423,8 +422,6 @@ module ProjectsHelper
end end
end end
=======
>>>>>>> ce/master
def readme_cache_key def readme_cache_key
sha = @project.commit.try(:sha) || 'nil' sha = @project.commit.try(:sha) || 'nil'
[@project.path_with_namespace, sha, "readme"].join('-') [@project.path_with_namespace, sha, "readme"].join('-')
......
...@@ -110,14 +110,14 @@ module SortingHelper ...@@ -110,14 +110,14 @@ module SortingHelper
'Most popular' 'Most popular'
end end
<<<<<<< HEAD
def sort_title_more_weight def sort_title_more_weight
'More weight' 'More weight'
end end
def sort_title_less_weight def sort_title_less_weight
'Less weight' 'Less weight'
======= end
def sort_title_last_joined def sort_title_last_joined
'Last joined' 'Last joined'
end end
...@@ -160,7 +160,6 @@ module SortingHelper ...@@ -160,7 +160,6 @@ module SortingHelper
def sort_value_name_desc def sort_value_name_desc
'name_desc' 'name_desc'
>>>>>>> ce/master
end end
def sort_value_priority def sort_value_priority
......
...@@ -91,11 +91,8 @@ class Project < ActiveRecord::Base ...@@ -91,11 +91,8 @@ class Project < ActiveRecord::Base
has_one :mattermost_slash_commands_service, dependent: :destroy has_one :mattermost_slash_commands_service, dependent: :destroy
has_one :mattermost_notification_service, dependent: :destroy has_one :mattermost_notification_service, dependent: :destroy
has_one :slack_notification_service, dependent: :destroy has_one :slack_notification_service, dependent: :destroy
<<<<<<< HEAD
has_one :jenkins_service, dependent: :destroy has_one :jenkins_service, dependent: :destroy
has_one :jenkins_deprecated_service, dependent: :destroy has_one :jenkins_deprecated_service, dependent: :destroy
=======
>>>>>>> ce/master
has_one :buildkite_service, dependent: :destroy has_one :buildkite_service, dependent: :destroy
has_one :bamboo_service, dependent: :destroy has_one :bamboo_service, dependent: :destroy
has_one :teamcity_service, dependent: :destroy has_one :teamcity_service, dependent: :destroy
...@@ -106,11 +103,8 @@ class Project < ActiveRecord::Base ...@@ -106,11 +103,8 @@ class Project < ActiveRecord::Base
has_one :bugzilla_service, dependent: :destroy has_one :bugzilla_service, dependent: :destroy
has_one :gitlab_issue_tracker_service, dependent: :destroy, inverse_of: :project has_one :gitlab_issue_tracker_service, dependent: :destroy, inverse_of: :project
has_one :external_wiki_service, dependent: :destroy has_one :external_wiki_service, dependent: :destroy
<<<<<<< HEAD
has_one :index_status, dependent: :destroy
=======
has_one :kubernetes_service, dependent: :destroy, inverse_of: :project has_one :kubernetes_service, dependent: :destroy, inverse_of: :project
>>>>>>> ce/master has_one :index_status, dependent: :destroy
has_one :forked_project_link, dependent: :destroy, foreign_key: "forked_to_project_id" has_one :forked_project_link, dependent: :destroy, foreign_key: "forked_to_project_id"
has_one :forked_from_project, through: :forked_project_link has_one :forked_from_project, through: :forked_project_link
......
...@@ -20,15 +20,11 @@ class GroupMemberPolicy < BasePolicy ...@@ -20,15 +20,11 @@ class GroupMemberPolicy < BasePolicy
end end
def additional_rules! def additional_rules!
<<<<<<< HEAD
can_override = Ability.allowed?(@user, :override_group_member, @subject.group) can_override = Ability.allowed?(@user, :override_group_member, @subject.group)
if can_override if can_override
can! :override_group_member if @subject.ldap? can! :override_group_member if @subject.ldap?
can! :update_group_member unless @subject.ldap? && !@subject.override? can! :update_group_member unless @subject.ldap? && !@subject.override?
end end
=======
# This is meant to be overriden in EE
>>>>>>> ce/master
end end
end end
...@@ -47,13 +47,9 @@ class GroupPolicy < BasePolicy ...@@ -47,13 +47,9 @@ class GroupPolicy < BasePolicy
end end
def additional_rules!(master) def additional_rules!(master)
<<<<<<< HEAD
if @subject.ldap_synced? if @subject.ldap_synced?
cannot! :admin_group_member cannot! :admin_group_member
can! :override_group_member if master can! :override_group_member if master
end end
=======
# This is meant to be overriden in EE
>>>>>>> ce/master
end end
end end
...@@ -41,19 +41,6 @@ ...@@ -41,19 +41,6 @@
- if mr_closes_issues.present? || mr_issues_mentioned_but_not_closing.present? - if mr_closes_issues.present? || mr_issues_mentioned_but_not_closing.present?
.mr-widget-footer .mr-widget-footer
%span %span
<<<<<<< HEAD
%i.fa.fa-check
Accepting this merge request will close #{"issue".pluralize(mr_closes_issues.size)}
= succeed '.' do
!= markdown issues_sentence(mr_closes_issues), pipeline: :gfm, author: @merge_request.author
= mr_assign_issues_link
- if @merge_request.approvals.any?
.mr-widget-footer.approved-by-users
Approved by
- @merge_request.approved_by_users.each do |user|
= link_to_member(@project, user, name: false, size: 24)
=======
= icon('check') = icon('check')
- if mr_closes_issues.present? - if mr_closes_issues.present?
Accepting this merge request will close #{"issue".pluralize(mr_closes_issues.size)} Accepting this merge request will close #{"issue".pluralize(mr_closes_issues.size)}
...@@ -65,5 +52,8 @@ ...@@ -65,5 +52,8 @@
!= markdown issues_sentence(mr_issues_mentioned_but_not_closing), pipeline: :gfm, author: @merge_request.author != markdown issues_sentence(mr_issues_mentioned_but_not_closing), pipeline: :gfm, author: @merge_request.author
#{mr_issues_mentioned_but_not_closing.size > 1 ? 'are' : 'is'} mentioned but will not closed. #{mr_issues_mentioned_but_not_closing.size > 1 ? 'are' : 'is'} mentioned but will not closed.
- if @merge_request.approvals.any?
>>>>>>> ce/master .mr-widget-footer.approved-by-users
Approved by
- @merge_request.approved_by_users.each do |user|
= link_to_member(@project, user, name: false, size: 24)
...@@ -37,7 +37,6 @@ ...@@ -37,7 +37,6 @@
Remove source branch Remove source branch
.accept-control.right .accept-control.right
<<<<<<< HEAD
- if @project.merge_requests_ff_only_enabled - if @project.merge_requests_ff_only_enabled
Fast-forward merge without a merge commit Fast-forward merge without a merge commit
- else - else
...@@ -46,21 +45,12 @@ ...@@ -46,21 +45,12 @@
Modify commit message Modify commit message
- unless @project.merge_requests_ff_only_enabled - unless @project.merge_requests_ff_only_enabled
.js-toggle-content.hide.prepend-top-default
= render 'shared/commit_message_container', params: params,
text: @merge_request.merge_commit_message,
rows: 14, hint: true
=======
= link_to "#", class: "modify-merge-commit-link js-toggle-button" do
= icon('edit')
Modify commit message
.js-toggle-content.hide.prepend-top-default .js-toggle-content.hide.prepend-top-default
= render 'shared/commit_message_container', params: params, = render 'shared/commit_message_container', params: params,
message_with_description: @merge_request.merge_commit_message(include_description: true), message_with_description: @merge_request.merge_commit_message(include_description: true),
message_without_description: @merge_request.merge_commit_message, message_without_description: @merge_request.merge_commit_message,
text: @merge_request.merge_commit_message, text: @merge_request.merge_commit_message,
rows: 14, hint: true rows: 14, hint: true
>>>>>>> ce/master
= hidden_field_tag :merge_when_build_succeeds, "", autocomplete: "off" = hidden_field_tag :merge_when_build_succeeds, "", autocomplete: "off"
......
--- ---
<<<<<<< HEAD
title: 'API: Memoize the current_user so that the sudo can work properly' title: 'API: Memoize the current_user so that the sudo can work properly'
merge_request: 8017 merge_request: 8017
author: author:
=======
title: 'API: Memoize the current_user so that sudo can work properly'
merge_request: 8017
author:
>>>>>>> ce/master
...@@ -90,12 +90,9 @@ module Gitlab ...@@ -90,12 +90,9 @@ module Gitlab
config.assets.precompile << "print.css" config.assets.precompile << "print.css"
config.assets.precompile << "notify.css" config.assets.precompile << "notify.css"
config.assets.precompile << "mailers/*.css" config.assets.precompile << "mailers/*.css"
<<<<<<< HEAD
config.assets.precompile << "lib/vue_resource.js" config.assets.precompile << "lib/vue_resource.js"
=======
config.assets.precompile << "katex.css" config.assets.precompile << "katex.css"
config.assets.precompile << "katex.js" config.assets.precompile << "katex.js"
>>>>>>> ce/master
config.assets.precompile << "graphs/graphs_bundle.js" config.assets.precompile << "graphs/graphs_bundle.js"
config.assets.precompile << "users/users_bundle.js" config.assets.precompile << "users/users_bundle.js"
config.assets.precompile << "network/network_bundle.js" config.assets.precompile << "network/network_bundle.js"
......
...@@ -153,7 +153,6 @@ production: &base ...@@ -153,7 +153,6 @@ production: &base
# The location where LFS objects are stored (default: shared/lfs-objects). # The location where LFS objects are stored (default: shared/lfs-objects).
# storage_path: shared/lfs-objects # storage_path: shared/lfs-objects
<<<<<<< HEAD
## GitLab Pages ## GitLab Pages
pages: pages:
enabled: false enabled: false
...@@ -168,13 +167,12 @@ production: &base ...@@ -168,13 +167,12 @@ production: &base
https: false # Set to true if you serve the pages with HTTPS https: false # Set to true if you serve the pages with HTTPS
# external_http: "1.1.1.1:80" # If defined, enables custom domain support in GitLab Pages # external_http: "1.1.1.1:80" # If defined, enables custom domain support in GitLab Pages
# external_https: "1.1.1.1:443" # If defined, enables custom domain and certificate support in GitLab Pages # external_https: "1.1.1.1:443" # If defined, enables custom domain and certificate support in GitLab Pages
=======
## Mattermost ## Mattermost
## For enabling Add to Mattermost button ## For enabling Add to Mattermost button
mattermost: mattermost:
enabled: false enabled: false
host: 'https://mattermost.example.com' host: 'https://mattermost.example.com'
>>>>>>> ce/master
## Gravatar ## Gravatar
## For Libravatar see: http://doc.gitlab.com/ce/customization/libravatar.html ## For Libravatar see: http://doc.gitlab.com/ce/customization/libravatar.html
......
...@@ -840,23 +840,17 @@ ActiveRecord::Schema.define(version: 20161213172958) do ...@@ -840,23 +840,17 @@ ActiveRecord::Schema.define(version: 20161213172958) do
t.datetime "ldap_sync_last_sync_at" t.datetime "ldap_sync_last_sync_at"
t.datetime "deleted_at" t.datetime "deleted_at"
t.boolean "lfs_enabled" t.boolean "lfs_enabled"
<<<<<<< HEAD
t.integer "repository_size_limit" t.integer "repository_size_limit"
=======
t.text "description_html" t.text "description_html"
>>>>>>> ce/master
t.integer "parent_id" t.integer "parent_id"
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
add_index "namespaces", ["deleted_at"], name: "index_namespaces_on_deleted_at", using: :btree add_index "namespaces", ["deleted_at"], name: "index_namespaces_on_deleted_at", using: :btree
<<<<<<< HEAD
add_index "namespaces", ["ldap_sync_last_successful_update_at"], name: "index_namespaces_on_ldap_sync_last_successful_update_at", using: :btree add_index "namespaces", ["ldap_sync_last_successful_update_at"], name: "index_namespaces_on_ldap_sync_last_successful_update_at", using: :btree
add_index "namespaces", ["ldap_sync_last_update_at"], name: "index_namespaces_on_ldap_sync_last_update_at", using: :btree add_index "namespaces", ["ldap_sync_last_update_at"], name: "index_namespaces_on_ldap_sync_last_update_at", using: :btree
add_index "namespaces", ["name"], name: "index_namespaces_on_name", unique: true, using: :btree add_index "namespaces", ["name"], name: "index_namespaces_on_name", unique: true, using: :btree
=======
add_index "namespaces", ["name", "parent_id"], name: "index_namespaces_on_name_and_parent_id", unique: true, using: :btree add_index "namespaces", ["name", "parent_id"], name: "index_namespaces_on_name_and_parent_id", unique: true, using: :btree
>>>>>>> ce/master
add_index "namespaces", ["name"], name: "index_namespaces_on_name_trigram", using: :gin, opclasses: {"name"=>"gin_trgm_ops"} add_index "namespaces", ["name"], name: "index_namespaces_on_name_trigram", using: :gin, opclasses: {"name"=>"gin_trgm_ops"}
add_index "namespaces", ["owner_id"], name: "index_namespaces_on_owner_id", using: :btree add_index "namespaces", ["owner_id"], name: "index_namespaces_on_owner_id", using: :btree
add_index "namespaces", ["parent_id", "id"], name: "index_namespaces_on_parent_id_and_id", unique: true, using: :btree add_index "namespaces", ["parent_id", "id"], name: "index_namespaces_on_parent_id_and_id", unique: true, using: :btree
......
...@@ -8,14 +8,9 @@ ...@@ -8,14 +8,9 @@
- [Custom templates for issues and merge requests](customization/issue_and_merge_request_template.md) Pre-fill the description of issues and merge requests to your liking. - [Custom templates for issues and merge requests](customization/issue_and_merge_request_template.md) Pre-fill the description of issues and merge requests to your liking.
- [GitLab as OAuth2 authentication service provider](integration/oauth_provider.md). It allows you to login to other applications from GitLab. - [GitLab as OAuth2 authentication service provider](integration/oauth_provider.md). It allows you to login to other applications from GitLab.
- [Container Registry](user/project/container_registry.md) Learn how to use GitLab Container Registry. - [Container Registry](user/project/container_registry.md) Learn how to use GitLab Container Registry.
<<<<<<< HEAD
- [GitLab Basics](gitlab-basics/README.md) Find step by step how to start working on your commandline and on GitLab.
- [GitLab Pages](pages/README.md) Using GitLab Pages.
- [Importing to GitLab](workflow/importing/README.md).
=======
- [GitLab basics](gitlab-basics/README.md) Find step by step how to start working on your commandline and on GitLab. - [GitLab basics](gitlab-basics/README.md) Find step by step how to start working on your commandline and on GitLab.
- [GitLab Pages](pages/README.md) Using GitLab Pages.
- [Importing to GitLab](workflow/importing/README.md) Import your projects from GitHub, Bitbucket, GitLab.com, FogBugz and SVN into GitLab. - [Importing to GitLab](workflow/importing/README.md) Import your projects from GitHub, Bitbucket, GitLab.com, FogBugz and SVN into GitLab.
>>>>>>> ce/master
- [Importing and exporting projects between instances](user/project/settings/import_export.md). - [Importing and exporting projects between instances](user/project/settings/import_export.md).
- [Koding](user/project/koding.md) Learn how to use Koding, the online IDE. - [Koding](user/project/koding.md) Learn how to use Koding, the online IDE.
- [Markdown](user/markdown.md) GitLab's advanced formatting system. - [Markdown](user/markdown.md) GitLab's advanced formatting system.
......
...@@ -4,10 +4,6 @@ Feature: Admin Settings ...@@ -4,10 +4,6 @@ Feature: Admin Settings
Given I sign in as an admin Given I sign in as an admin
And I visit admin settings page And I visit admin settings page
Scenario: Change application settings
When I modify settings and save form
Then I should see application settings saved
Scenario: Help text Scenario: Help text
When I set the help text When I set the help text
Then I should see the help text Then I should see the help text
...@@ -15,13 +11,3 @@ Feature: Admin Settings ...@@ -15,13 +11,3 @@ Feature: Admin Settings
Then I should see the help text Then I should see the help text
And I logout And I logout
Then I should see the help text Then I should see the help text
Scenario: Change Slack Service Template settings
When I click on "Service Templates"
And I click on "Slack" service
And I fill out Slack settings
Then I check all events and submit form
And I should see service template settings saved
Then I click on "Slack" service
And I should see all checkboxes checked
And I should see Slack settings saved
...@@ -207,7 +207,6 @@ module SharedPaths ...@@ -207,7 +207,6 @@ module SharedPaths
visit admin_teams_path visit admin_teams_path
end end
<<<<<<< HEAD
step 'I visit admin email page' do step 'I visit admin email page' do
visit admin_email_path visit admin_email_path
end end
...@@ -216,8 +215,6 @@ module SharedPaths ...@@ -216,8 +215,6 @@ module SharedPaths
visit admin_application_settings_path visit admin_application_settings_path
end end
=======
>>>>>>> ce/master
step 'I visit spam logs page' do step 'I visit spam logs page' do
visit admin_spam_logs_path visit admin_spam_logs_path
end end
......
...@@ -348,11 +348,7 @@ module API ...@@ -348,11 +348,7 @@ module API
def sudo! def sudo!
return unless sudo_identifier return unless sudo_identifier
<<<<<<< HEAD
return unless initial_current_user.is_a?(User)
=======
return unless initial_current_user return unless initial_current_user
>>>>>>> ce/master
unless initial_current_user.is_admin? unless initial_current_user.is_admin?
forbidden!('Must be admin to use sudo') forbidden!('Must be admin to use sudo')
...@@ -363,11 +359,7 @@ module API ...@@ -363,11 +359,7 @@ module API
forbidden!('Private token must be specified in order to use sudo') forbidden!('Private token must be specified in order to use sudo')
end end
<<<<<<< HEAD
sudoed_user = User.by_username_or_id(sudo_identifier)
=======
sudoed_user = find_user(sudo_identifier) sudoed_user = find_user(sudo_identifier)
>>>>>>> ce/master
if sudoed_user if sudoed_user
@current_user = sudoed_user @current_user = sudoed_user
...@@ -377,21 +369,7 @@ module API ...@@ -377,21 +369,7 @@ module API
end end
def sudo_identifier def sudo_identifier
<<<<<<< HEAD
return @sudo_identifier if defined?(@sudo_identifier)
identifier ||= params[SUDO_PARAM] || env[SUDO_HEADER]
# Regex for integers
@sudo_identifier =
if !!(identifier =~ /\A[0-9]+\z/)
identifier.to_i
else
identifier
end
=======
@sudo_identifier ||= params[SUDO_PARAM] || env[SUDO_HEADER] @sudo_identifier ||= params[SUDO_PARAM] || env[SUDO_HEADER]
>>>>>>> ce/master
end end
def add_pagination_headers(paginated_data) def add_pagination_headers(paginated_data)
......
...@@ -70,12 +70,8 @@ ...@@ -70,12 +70,8 @@
<h3>Whoops, something went wrong on our end.</h3> <h3>Whoops, something went wrong on our end.</h3>
<hr /> <hr />
<p>Try refreshing the page, or going back and attempting the action again.</p> <p>Try refreshing the page, or going back and attempting the action again.</p>
<<<<<<< HEAD
<p><a href="/help" >Please contact your GitLab administrator</a> if this problem persists.</p>
=======
<p>Please contact your GitLab administrator if this problem persists.</p> <p>Please contact your GitLab administrator if this problem persists.</p>
<a href="javascript:history.back()">Go back</a> <a href="javascript:history.back()">Go back</a>
>>>>>>> ce/master
</div> </div>
</body> </body>
</html> </html>
...@@ -70,12 +70,8 @@ ...@@ -70,12 +70,8 @@
<h3>Whoops, GitLab is taking too much time to respond.</h3> <h3>Whoops, GitLab is taking too much time to respond.</h3>
<hr /> <hr />
<p>Try refreshing the page, or going back and attempting the action again.</p> <p>Try refreshing the page, or going back and attempting the action again.</p>
<<<<<<< HEAD
<p><a href="/help" >Please contact your GitLab administrator</a> if this problem persists.</p>
=======
<p>Please contact your GitLab administrator if this problem persists.</p> <p>Please contact your GitLab administrator if this problem persists.</p>
<a href="javascript:history.back()">Go back</a> <a href="javascript:history.back()">Go back</a>
>>>>>>> ce/master
</div> </div>
</body> </body>
</html> </html>
...@@ -17,24 +17,7 @@ feature 'Admin updates settings', feature: true do ...@@ -17,24 +17,7 @@ feature 'Admin updates settings', feature: true do
expect(page).to have_content "Application settings saved successfully" expect(page).to have_content "Application settings saved successfully"
end end
<<<<<<< HEAD:features/steps/admin/settings.rb
step 'I set the help text' do
fill_in 'Help text', with: help_text
click_button 'Save'
end
step 'I should see the help text' do
expect(page).to have_content help_text
end
step 'I go to help page' do
visit '/help'
end
step 'I click on "Service Templates"' do
=======
scenario 'Change Slack Service template settings' do scenario 'Change Slack Service template settings' do
>>>>>>> ce/master:spec/features/admin/admin_settings_spec.rb
click_link 'Service Templates' click_link 'Service Templates'
click_link 'Slack' click_link 'Slack'
fill_in 'Webhook', with: 'http://localhost' fill_in 'Webhook', with: 'http://localhost'
...@@ -57,10 +40,6 @@ feature 'Admin updates settings', feature: true do ...@@ -57,10 +40,6 @@ feature 'Admin updates settings', feature: true do
expect(find('#service_push_channel').value).to eq '#test_channel' expect(find('#service_push_channel').value).to eq '#test_channel'
end end
<<<<<<< HEAD:features/steps/admin/settings.rb
def help_text
'For help related to GitLab contact Marc Smith at marc@smith.example or find him in office 42.'
=======
def check_all_events def check_all_events
page.check('Active') page.check('Active')
page.check('Push') page.check('Push')
...@@ -70,6 +49,5 @@ feature 'Admin updates settings', feature: true do ...@@ -70,6 +49,5 @@ feature 'Admin updates settings', feature: true do
page.check('Merge request') page.check('Merge request')
page.check('Build') page.check('Build')
page.check('Pipeline') page.check('Pipeline')
>>>>>>> ce/master:spec/features/admin/admin_settings_spec.rb
end end
end end
...@@ -113,13 +113,8 @@ ...@@ -113,13 +113,8 @@
}); });
}); });
describe('::getAwardUrl', function() { describe('::getAwardUrl', function() {
<<<<<<< HEAD
return it('returns the url for request', function() {
return expect(awardsHandler.getAwardUrl()).toBe('/gitlab-org/gitlab-test/issues/8/toggle_award_emoji');
=======
return it('should return the url for request', function() { return it('should return the url for request', function() {
return expect(awardsHandler.getAwardUrl()).toBe('http://test.host/frontend-fixtures/issues-project/issues/1/toggle_award_emoji'); return expect(awardsHandler.getAwardUrl()).toBe('http://test.host/frontend-fixtures/issues-project/issues/1/toggle_award_emoji');
>>>>>>> ce/master
}); });
}); });
describe('::addAward and ::checkMutuality', function() { describe('::addAward and ::checkMutuality', function() {
......
...@@ -83,7 +83,6 @@ describe Gitlab::Auth, lib: true do ...@@ -83,7 +83,6 @@ describe Gitlab::Auth, lib: true do
expect(gl_auth).to receive(:rate_limit!).with('ip', success: true, login: 'oauth2') expect(gl_auth).to receive(:rate_limit!).with('ip', success: true, login: 'oauth2')
expect(gl_auth.find_for_git_client("oauth2", token.token, project: nil, ip: 'ip')).to eq(Gitlab::Auth::Result.new(user, nil, :oauth, read_authentication_abilities)) expect(gl_auth.find_for_git_client("oauth2", token.token, project: nil, ip: 'ip')).to eq(Gitlab::Auth::Result.new(user, nil, :oauth, read_authentication_abilities))
end end
<<<<<<< HEAD
it 'fails for OAuth tokens with other scopes' do it 'fails for OAuth tokens with other scopes' do
user = create(:user) user = create(:user)
...@@ -108,32 +107,6 @@ describe Gitlab::Auth, lib: true do ...@@ -108,32 +107,6 @@ describe Gitlab::Auth, lib: true do
user = create(:user) user = create(:user)
personal_access_token = create(:personal_access_token, user: user, scopes: ['read_user']) personal_access_token = create(:personal_access_token, user: user, scopes: ['read_user'])
=======
it 'fails for OAuth tokens with other scopes' do
user = create(:user)
application = Doorkeeper::Application.create!(name: "MyApp", redirect_uri: "https://app.com", owner: user)
token = Doorkeeper::AccessToken.create!(application_id: application.id, resource_owner_id: user.id, scopes: "read_user")
expect(gl_auth).to receive(:rate_limit!).with('ip', success: false, login: 'oauth2')
expect(gl_auth.find_for_git_client("oauth2", token.token, project: nil, ip: 'ip')).to eq(Gitlab::Auth::Result.new(nil, nil))
end
end
context "while using personal access tokens as passwords" do
it 'succeeds for personal access tokens with the `api` scope' do
user = create(:user)
personal_access_token = create(:personal_access_token, user: user, scopes: ['api'])
expect(gl_auth).to receive(:rate_limit!).with('ip', success: true, login: user.email)
expect(gl_auth.find_for_git_client(user.email, personal_access_token.token, project: nil, ip: 'ip')).to eq(Gitlab::Auth::Result.new(user, nil, :personal_token, full_authentication_abilities))
end
it 'fails for personal access tokens with other scopes' do
user = create(:user)
personal_access_token = create(:personal_access_token, user: user, scopes: ['read_user'])
>>>>>>> ce/master
expect(gl_auth).to receive(:rate_limit!).with('ip', success: false, login: user.email) expect(gl_auth).to receive(:rate_limit!).with('ip', success: false, login: user.email)
expect(gl_auth.find_for_git_client(user.email, personal_access_token.token, project: nil, ip: 'ip')).to eq(Gitlab::Auth::Result.new(nil, nil)) expect(gl_auth.find_for_git_client(user.email, personal_access_token.token, project: nil, ip: 'ip')).to eq(Gitlab::Auth::Result.new(nil, nil))
end end
......
...@@ -2,10 +2,7 @@ require 'spec_helper' ...@@ -2,10 +2,7 @@ require 'spec_helper'
describe ChatMessage::PipelineMessage do describe ChatMessage::PipelineMessage do
subject { described_class.new(args) } subject { described_class.new(args) }
<<<<<<< HEAD:spec/models/project_services/chat_message/pipeline_message_spec.rb
=======
>>>>>>> ce/master:spec/models/project_services/chat_message/pipeline_message_spec.rb
let(:user) { { name: 'hacker' } } let(:user) { { name: 'hacker' } }
let(:args) do let(:args) do
......
...@@ -17,22 +17,14 @@ describe API::Helpers, api: true do ...@@ -17,22 +17,14 @@ describe API::Helpers, api: true do
clear_env clear_env
clear_param clear_param
env[API::APIGuard::PRIVATE_TOKEN_HEADER] = user_or_token.respond_to?(:private_token) ? user_or_token.private_token : user_or_token env[API::APIGuard::PRIVATE_TOKEN_HEADER] = user_or_token.respond_to?(:private_token) ? user_or_token.private_token : user_or_token
<<<<<<< HEAD:spec/requests/api/helpers_spec.rb
env[API::Helpers::SUDO_HEADER] = identifier
=======
env[API::Helpers::SUDO_HEADER] = identifier.to_s env[API::Helpers::SUDO_HEADER] = identifier.to_s
>>>>>>> ce/master:spec/requests/api/helpers_spec.rb
end end
def set_param(user_or_token, identifier) def set_param(user_or_token, identifier)
clear_env clear_env
clear_param clear_param
params[API::APIGuard::PRIVATE_TOKEN_PARAM] = user_or_token.respond_to?(:private_token) ? user_or_token.private_token : user_or_token params[API::APIGuard::PRIVATE_TOKEN_PARAM] = user_or_token.respond_to?(:private_token) ? user_or_token.private_token : user_or_token
<<<<<<< HEAD:spec/requests/api/helpers_spec.rb
params[API::Helpers::SUDO_PARAM] = identifier
=======
params[API::Helpers::SUDO_PARAM] = identifier.to_s params[API::Helpers::SUDO_PARAM] = identifier.to_s
>>>>>>> ce/master:spec/requests/api/helpers_spec.rb
end end
def clear_env def clear_env
......
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