Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
807e4ad3
Commit
807e4ad3
authored
Jul 15, 2017
by
Lin Jen-Shin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Resolve conflicts
parent
5f560438
Changes
12
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
23 additions
and
116 deletions
+23
-116
Gemfile.lock
Gemfile.lock
+0
-3
app/models/merge_request.rb
app/models/merge_request.rb
+0
-6
app/views/layouts/_broadcast.html.haml
app/views/layouts/_broadcast.html.haml
+0
-4
app/views/projects/protected_branches/_protected_branch.html.haml
...s/projects/protected_branches/_protected_branch.html.haml
+0
-4
app/views/projects/protected_branches/shared/_dropdown.html.haml
...ws/projects/protected_branches/shared/_dropdown.html.haml
+0
-0
app/views/projects/protected_branches/shared/_dropdown.html.haml~upstream_master
...ected_branches/shared/_dropdown.html.haml~upstream_master
+0
-15
app/views/projects/protected_tags/_protected_tag.html.haml
app/views/projects/protected_tags/_protected_tag.html.haml
+0
-4
app/views/projects/settings/repository/show.html.haml
app/views/projects/settings/repository/show.html.haml
+0
-8
lib/api/v3/entities.rb
lib/api/v3/entities.rb
+0
-33
spec/models/user_spec.rb
spec/models/user_spec.rb
+22
-22
spec/requests/api/settings_spec.rb
spec/requests/api/settings_spec.rb
+0
-13
spec/spec_helper.rb
spec/spec_helper.rb
+1
-4
No files found.
Gemfile.lock
View file @
807e4ad3
...
...
@@ -1048,11 +1048,8 @@ DEPENDENCIES
minitest (~> 5.7.0)
mousetrap-rails (~> 1.4.6)
mysql2 (~> 0.4.5)
<<<<<<< HEAD
net-ldap
net-ntp
=======
>>>>>>> upstream/master
nokogiri (~> 1.6.7, >= 1.6.7.2)
oauth2 (~> 1.4)
octokit (~> 4.6.2)
...
...
app/models/merge_request.rb
View file @
807e4ad3
...
...
@@ -35,15 +35,9 @@ class MergeRequest < ActiveRecord::Base
after_create
:ensure_merge_request_diff
,
unless: :importing?
after_update
:reload_diff_if_branch_changed
<<<<<<<
HEAD
delegate
:commits
,
:real_size
,
:commit_shas
,
:commits_count
,
to: :merge_request_diff
,
prefix:
nil
delegate
:codeclimate_artifact
,
to: :head_pipeline
,
prefix: :head
,
allow_nil:
true
delegate
:codeclimate_artifact
,
to: :base_pipeline
,
prefix: :base
,
allow_nil:
true
=======
>>>>>>>
upstream
/
master
# When this attribute is true some MR validation is ignored
# It allows us to close or modify broken merge requests
attr_accessor
:allow_broken
...
...
app/views/layouts/_broadcast.html.haml
View file @
807e4ad3
<
<<<<<<
HEAD
-
if
license_message
.
present?
.broadcast-message
=
icon
(
'bullhorn'
)
=
license_message
-
BroadcastMessage
.
current
.
each
do
|
message
|
==
=====
-
BroadcastMessage
.
current
&
.
each
do
|
message
|
>
>>>>>> upstream/master
=
broadcast_message
(
message
)
app/views/projects/protected_branches/_protected_branch.html.haml
View file @
807e4ad3
=
render
layout:
'projects/protected_branches/shared/protected_branch'
,
locals:
{
protected_branch:
protected_branch
}
do
<
<<<<<<
HEAD
=
render
partial:
'projects/protected_branches/ee/fallback_update_protected_branch'
,
locals:
{
protected_branch:
protected_branch
}
==
=====
=
render
partial:
'projects/protected_branches/update_protected_branch'
,
locals:
{
protected_branch:
protected_branch
}
>
>>>>>> upstream/master
app/views/projects/protected_branches/shared/_dropdown.html.haml
~HEAD
→
app/views/projects/protected_branches/shared/_dropdown.html.haml
View file @
807e4ad3
File moved
app/views/projects/protected_branches/shared/_dropdown.html.haml~upstream_master
deleted
100644 → 0
View file @
5f560438
= f.hidden_field(:name)
= dropdown_tag('Select branch or create wildcard',
options: { toggle_class: 'js-protected-branch-select js-filter-submit wide git-revision-dropdown-toggle',
filter: true, dropdown_class: "dropdown-menu-selectable git-revision-dropdown", placeholder: "Search protected branches",
footer_content: true,
data: { show_no: true, show_any: true, show_upcoming: true,
selected: params[:protected_branch_name],
project_id: @project.try(:id) } }) do
%ul.dropdown-footer-list
%li
%button{ class: "create-new-protected-branch-button js-create-new-protected-branch", title: "New Protected Branch" }
Create wildcard
%code
app/views/projects/protected_tags/_protected_tag.html.haml
View file @
807e4ad3
=
render
layout:
'projects/protected_tags/shared/protected_tag'
,
locals:
{
protected_tag:
protected_tag
}
do
<
<<<<<<
HEAD
=
render
partial:
'projects/protected_tags/ee/fallback_update_protected_tag'
,
locals:
{
protected_tag:
protected_tag
}
==
=====
=
render
partial:
'projects/protected_tags/update_protected_tag'
,
locals:
{
protected_tag:
protected_tag
}
>
>>>>>> upstream/master
app/views/projects/settings/repository/show.html.haml
View file @
807e4ad3
...
...
@@ -6,17 +6,13 @@
=
page_specific_javascript_bundle_tag
(
'common_vue'
)
=
page_specific_javascript_bundle_tag
(
'deploy_keys'
)
<
<<<<<<
HEAD
=
render
"projects/push_rules/index"
=
render
"projects/mirrors/show"
==
=====
>
>>>>>> upstream/master
-# Protected branches & tags use a lot of nested partials.
-# The shared parts of the views can be found in the `shared` directory.
-# Those are used throughout the actual views. These `shared` views are then
-# reused in EE.
<
<<<<<<
HEAD
-
if
@project
.
feature_available?
(
:protected_refs_for_users
,
current_user
)
=
render
"projects/protected_branches/ee/index"
=
render
"projects/protected_tags/ee/index"
...
...
@@ -24,8 +20,4 @@
=
render
"projects/protected_branches/index"
=
render
"projects/protected_tags/index"
==
=====
=
render
"projects/protected_branches/index"
=
render
"projects/protected_tags/index"
>
>>>>>> upstream/master
=
render
@deploy_keys
lib/api/v3/entities.rb
View file @
807e4ad3
...
...
@@ -46,39 +46,6 @@ module API
expose
:awardable_id
,
:awardable_type
end
class
ApplicationSetting
<
Grape
::
Entity
expose
:id
expose
:default_projects_limit
expose
:signup_enabled
expose
:signin_enabled
expose
:gravatar_enabled
expose
:sign_in_text
expose
:after_sign_up_text
expose
:created_at
expose
:updated_at
expose
:home_page_url
expose
:default_branch_protection
expose
:restricted_visibility_levels
expose
:max_attachment_size
expose
:session_expire_delay
expose
:default_project_visibility
expose
:default_snippet_visibility
expose
:default_group_visibility
expose
:domain_whitelist
expose
:domain_blacklist_enabled
expose
:domain_blacklist
expose
:user_oauth_applications
expose
:after_sign_out_path
expose
:container_registry_token_expire_delay
expose
:repository_storage
expose
:repository_storages
expose
:koding_enabled
expose
:koding_url
expose
:plantuml_enabled
expose
:plantuml_url
expose
:terminal_max_session_time
end
class
Project
<
Grape
::
Entity
expose
:id
,
:description
,
:default_branch
,
:tag_list
expose
:public?
,
as: :public
...
...
spec/models/user_spec.rb
View file @
807e4ad3
...
...
@@ -2055,7 +2055,28 @@ describe User, models: true do
end
end
<<<<<<<
HEAD
describe
'#allow_password_authentication?'
do
context
'regular user'
do
let
(
:user
)
{
build
(
:user
)
}
it
'returns true when sign-in is enabled'
do
expect
(
user
.
allow_password_authentication?
).
to
be_truthy
end
it
'returns false when sign-in is disabled'
do
stub_application_setting
(
password_authentication_enabled:
false
)
expect
(
user
.
allow_password_authentication?
).
to
be_falsey
end
end
it
'returns false for ldap user'
do
user
=
create
(
:omniauth_user
,
provider:
'ldapmain'
)
expect
(
user
.
allow_password_authentication?
).
to
be_falsey
end
end
describe
'#forget_me!'
do
subject
{
create
(
:user
,
remember_created_at:
Time
.
now
)
}
...
...
@@ -2085,27 +2106,6 @@ describe User, models: true do
allow
(
Gitlab
::
Geo
).
to
receive
(
:secondary?
)
{
true
}
expect
{
subject
.
remember_me!
}.
not_to
change
(
subject
,
:remember_created_at
)
=======
describe
'#allow_password_authentication?'
do
context
'regular user'
do
let
(
:user
)
{
build
(
:user
)
}
it
'returns true when sign-in is enabled'
do
expect
(
user
.
allow_password_authentication?
).
to
be_truthy
end
it
'returns false when sign-in is disabled'
do
stub_application_setting
(
password_authentication_enabled:
false
)
expect
(
user
.
allow_password_authentication?
).
to
be_falsey
end
end
it
'returns false for ldap user'
do
user
=
create
(
:omniauth_user
,
provider:
'ldapmain'
)
expect
(
user
.
allow_password_authentication?
).
to
be_falsey
>>>>>>>
upstream
/
master
end
end
end
spec/requests/api/settings_spec.rb
View file @
807e4ad3
...
...
@@ -11,13 +11,9 @@ describe API::Settings, 'Settings' do
expect
(
response
).
to
have_http_status
(
200
)
expect
(
json_response
).
to
be_an
Hash
expect
(
json_response
[
'default_projects_limit'
]).
to
eq
(
42
)
<<<<<<<
HEAD
expect
(
json_response
[
'signin_enabled'
]).
to
be_truthy
expect
(
json_response
[
'repository_storages'
]).
to
eq
([
'default'
])
=======
expect
(
json_response
[
'password_authentication_enabled'
]).
to
be_truthy
expect
(
json_response
[
'repository_storage'
]).
to
eq
(
'default'
)
>>>>>>>
upstream
/
master
expect
(
json_response
[
'koding_enabled'
]).
to
be_falsey
expect
(
json_response
[
'koding_url'
]).
to
be_nil
expect
(
json_response
[
'plantuml_enabled'
]).
to
be_falsey
...
...
@@ -38,13 +34,8 @@ describe API::Settings, 'Settings' do
it
"updates application settings"
do
put
api
(
"/application/settings"
,
admin
),
default_projects_limit:
3
,
<<<<<<<
HEAD
signin_enabled:
false
,
repository_storages:
[
'custom'
],
=======
password_authentication_enabled:
false
,
repository_storage:
'custom'
,
>>>>>>>
upstream
/
master
koding_enabled:
true
,
koding_url:
'http://koding.example.com'
,
plantuml_enabled:
true
,
...
...
@@ -57,12 +48,8 @@ describe API::Settings, 'Settings' do
help_page_support_url:
'http://example.com/help'
expect
(
response
).
to
have_http_status
(
200
)
expect
(
json_response
[
'default_projects_limit'
]).
to
eq
(
3
)
<<<<<<<
HEAD
expect
(
json_response
[
'signin_enabled'
]).
to
be_falsey
=======
expect
(
json_response
[
'password_authentication_enabled'
]).
to
be_falsey
expect
(
json_response
[
'repository_storage'
]).
to
eq
(
'custom'
)
>>>>>>>
upstream
/
master
expect
(
json_response
[
'repository_storages'
]).
to
eq
([
'custom'
])
expect
(
json_response
[
'koding_enabled'
]).
to
be_truthy
expect
(
json_response
[
'koding_url'
]).
to
eq
(
'http://koding.example.com'
)
...
...
spec/spec_helper.rb
View file @
807e4ad3
...
...
@@ -59,12 +59,9 @@ RSpec.configure do |config|
config
.
include
ApiHelpers
,
:api
config
.
include
Gitlab
::
Routing
,
type: :routing
config
.
include
MigrationsHelpers
,
:migration
<<<<<<<
HEAD
config
.
include
StubFeatureFlags
config
.
include
EE
::
LicenseHelpers
config
.
include
Rails
.
application
.
routes
.
url_helpers
,
type: :routing
=======
config
.
include
StubFeatureFlags
>>>>>>>
upstream
/
master
config
.
infer_spec_type_from_file_location!
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment