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
5982811e
Commit
5982811e
authored
Jul 03, 2017
by
Sean McGivern
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix issuable finder and helper conflicts
parent
d75ddcf2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
48 deletions
+0
-48
app/finders/issuable_finder.rb
app/finders/issuable_finder.rb
+0
-3
app/helpers/issuables_helper.rb
app/helpers/issuables_helper.rb
+0
-4
spec/finders/issues_finder_spec.rb
spec/finders/issues_finder_spec.rb
+0
-41
No files found.
app/finders/issuable_finder.rb
View file @
5982811e
...
...
@@ -21,13 +21,10 @@
class
IssuableFinder
NONE
=
'0'
.
freeze
IRRELEVANT_PARAMS_FOR_CACHE_KEY
=
%i[utf8 sort page]
.
freeze
<<<<<<<
HEAD
SCALAR_PARAMS
=
%i(scope state group_id project_id milestone_title assignee_id search label_name sort assignee_username author_id author_username authorized_only due_date iids non_archived weight)
.
freeze
ARRAY_PARAMS
=
{
label_name:
[],
iids:
[]
}.
freeze
VALID_PARAMS
=
(
SCALAR_PARAMS
+
[
ARRAY_PARAMS
]).
freeze
=======
>>>>>>>
ce
-
com
/
master
attr_accessor
:current_user
,
:params
...
...
app/helpers/issuables_helper.rb
View file @
5982811e
...
...
@@ -165,10 +165,6 @@ module IssuablesHelper
}
state_title
=
titles
[
state
]
||
state
.
to_s
.
humanize
<<<<<<<
HEAD
=======
>>>>>>>
ce
-
com
/
master
count
=
issuables_count_for_state
(
issuable_type
,
state
)
html
=
content_tag
(
:span
,
state_title
)
...
...
spec/finders/issues_finder_spec.rb
View file @
5982811e
...
...
@@ -314,11 +314,8 @@ describe IssuesFinder do
describe
'#with_confidentiality_access_check'
do
let
(
:guest
)
{
create
(
:user
)
}
set
(
:authorized_user
)
{
create
(
:user
)
}
<<<<<<<
HEAD
let
(
:admin_user
)
{
create
(
:user
,
:admin
)
}
let
(
:auditor_user
)
{
create
(
:user
,
:auditor
)
}
=======
>>>>>>>
ce
-
com
/
master
set
(
:project
)
{
create
(
:empty_project
,
namespace:
authorized_user
.
namespace
)
}
set
(
:public_issue
)
{
create
(
:issue
,
project:
project
)
}
set
(
:confidential_issue
)
{
create
(
:issue
,
project:
project
,
confidential:
true
)
}
...
...
@@ -328,7 +325,6 @@ describe IssuesFinder do
context
'for an anonymous user'
do
subject
{
described_class
.
new
(
nil
,
params
).
with_confidentiality_access_check
}
<<<<<<<
HEAD
it
'returns only public issues'
do
expect
(
subject
).
to
include
(
public_issue
)
...
...
@@ -377,40 +373,6 @@ describe IssuesFinder do
context
'for an admin'
do
subject
{
described_class
.
new
(
admin_user
,
params
).
with_confidentiality_access_check
}
=======
it
'returns only public issues'
do
expect
(
subject
).
to
include
(
public_issue
)
expect
(
subject
).
not_to
include
(
confidential_issue
)
end
end
context
'for a user without project membership'
do
subject
{
described_class
.
new
(
user
,
params
).
with_confidentiality_access_check
}
it
'returns only public issues'
do
expect
(
subject
).
to
include
(
public_issue
)
expect
(
subject
).
not_to
include
(
confidential_issue
)
end
end
context
'for a guest user'
do
subject
{
described_class
.
new
(
guest
,
params
).
with_confidentiality_access_check
}
before
do
project
.
add_guest
(
guest
)
end
it
'returns only public issues'
do
expect
(
subject
).
to
include
(
public_issue
)
expect
(
subject
).
not_to
include
(
confidential_issue
)
end
end
context
'for a project member with access to view confidential issues'
do
subject
{
described_class
.
new
(
authorized_user
,
params
).
with_confidentiality_access_check
}
>>>>>>>
ce
-
com
/
master
it
'returns all issues'
do
expect
(
subject
).
to
include
(
public_issue
,
confidential_issue
)
end
...
...
@@ -482,7 +444,6 @@ describe IssuesFinder do
subject
end
end
<<<<<<<
HEAD
context
'for an auditor'
do
subject
{
described_class
.
new
(
auditor_user
,
params
).
with_confidentiality_access_check
}
...
...
@@ -511,8 +472,6 @@ describe IssuesFinder do
subject
end
end
=======
>>>>>>>
ce
-
com
/
master
end
end
end
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