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
0
Merge Requests
0
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
Jérome Perrin
gitlab-ce
Commits
d416a9d6
Commit
d416a9d6
authored
Aug 14, 2015
by
Stan Hu
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce
parents
58247662
3483024d
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
39 additions
and
1 deletion
+39
-1
CHANGELOG
CHANGELOG
+1
-0
app/controllers/projects/issues_controller.rb
app/controllers/projects/issues_controller.rb
+1
-1
spec/controllers/projects/issues_controller_spec.rb
spec/controllers/projects/issues_controller_spec.rb
+37
-0
No files found.
CHANGELOG
View file @
d416a9d6
...
@@ -28,6 +28,7 @@ v 7.14.0 (unreleased)
...
@@ -28,6 +28,7 @@ v 7.14.0 (unreleased)
- Fix file upload dialog for comment editing (Daniel Gerhardt)
- Fix file upload dialog for comment editing (Daniel Gerhardt)
- Set OmniAuth full_host parameter to ensure redirect URIs are correct (Stan Hu)
- Set OmniAuth full_host parameter to ensure redirect URIs are correct (Stan Hu)
- Return comments in created order in merge request API (Stan Hu)
- Return comments in created order in merge request API (Stan Hu)
- Disable internal issue tracker controller if external tracker is used (Stan Hu)
- Expire Rails cache entries after two weeks to prevent endless Redis growth
- Expire Rails cache entries after two weeks to prevent endless Redis growth
- Add support for destroying project milestones (Stan Hu)
- Add support for destroying project milestones (Stan Hu)
- Allow custom backup archive permissions
- Allow custom backup archive permissions
...
...
app/controllers/projects/issues_controller.rb
View file @
d416a9d6
...
@@ -131,7 +131,7 @@ class Projects::IssuesController < Projects::ApplicationController
...
@@ -131,7 +131,7 @@ class Projects::IssuesController < Projects::ApplicationController
end
end
def
module_enabled
def
module_enabled
return
render_404
unless
@project
.
issues_enabled
return
render_404
unless
@project
.
issues_enabled
&&
@project
.
default_issues_tracker?
end
end
# Since iids are implemented only in 6.1
# Since iids are implemented only in 6.1
...
...
spec/controllers/projects/issues_controller_spec.rb
0 → 100644
View file @
d416a9d6
require
(
'spec_helper'
)
describe
Projects
::
IssuesController
do
let
(
:project
)
{
create
(
:project
)
}
let
(
:user
)
{
create
(
:user
)
}
let
(
:issue
)
{
create
(
:issue
,
project:
project
)
}
before
do
sign_in
(
user
)
project
.
team
<<
[
user
,
:developer
]
controller
.
instance_variable_set
(
:@project
,
project
)
end
describe
"GET #index"
do
it
"returns index"
do
get
:index
,
namespace_id:
project
.
namespace
.
id
,
project_id:
project
.
id
expect
(
response
.
status
).
to
eq
(
200
)
end
it
"returns 404 when issues are disabled"
do
project
.
issues_enabled
=
false
project
.
save
get
:index
,
namespace_id:
project
.
namespace
.
id
,
project_id:
project
.
id
expect
(
response
.
status
).
to
eq
(
404
)
end
it
"returns 404 when external issue tracker is enabled"
do
allow
(
project
).
to
receive
(
:default_issues_tracker?
).
and_return
(
false
)
get
:index
,
namespace_id:
project
.
namespace
.
id
,
project_id:
project
.
id
expect
(
response
.
status
).
to
eq
(
404
)
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