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
76d981b5
Commit
76d981b5
authored
Sep 22, 2017
by
Oswaldo Ferreira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Send valid project path as name for Jira dev panel
parent
3db127f3
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
5 deletions
+18
-5
changelogs/unreleased-ee/send-valid-project-path-as-name-for-jira.yml
...nreleased-ee/send-valid-project-path-as-name-for-jira.yml
+5
-0
lib/api/github/entities.rb
lib/api/github/entities.rb
+1
-1
spec/requests/api/v3/github_spec.rb
spec/requests/api/v3/github_spec.rb
+12
-4
No files found.
changelogs/unreleased-ee/send-valid-project-path-as-name-for-jira.yml
0 → 100644
View file @
76d981b5
---
title
:
Send valid project path as name for Jira dev panel
merge_request
:
author
:
type
:
fixed
lib/api/github/entities.rb
View file @
76d981b5
...
...
@@ -11,7 +11,7 @@ module API
class
Repository
<
Grape
::
Entity
expose
:id
expose
:namespace
,
as: :owner
,
using:
Namespace
expose
:name
expose
:
path
,
as: :
name
end
class
BranchCommit
<
Grape
::
Entity
...
...
spec/requests/api/v3/github_spec.rb
View file @
76d981b5
...
...
@@ -40,15 +40,17 @@ describe API::V3::Github do
describe
'GET /users/:namespace/repos'
do
context
'authenticated'
do
it
'returns an array of projects with github format'
do
stub_licensed_features
(
jira_dev_panel_integration:
true
)
let
(
:group
)
{
create
(
:group
)
}
let!
(
:group_project
)
{
create
(
:project
,
group:
group
)
}
group
=
create
(
:group
)
create
(
:project
,
group:
group
)
before
do
stub_licensed_features
(
jira_dev_panel_integration:
true
)
group
.
add_master
(
user
)
get
v3_api
(
'/users/foo/repos'
,
user
)
end
it
'returns an array of projects with github format'
do
expect
(
response
).
to
have_http_status
(
200
)
expect
(
response
).
to
include_pagination_headers
expect
(
json_response
).
to
be_an
(
Array
)
...
...
@@ -56,6 +58,12 @@ describe API::V3::Github do
expect
(
response
).
to
match_response_schema
(
'entities/github/repositories'
)
end
it
'returns valid project path as name'
do
project_names
=
json_response
.
map
{
|
r
|
r
[
'name'
]
}
expect
(
project_names
).
to
include
(
project
.
path
,
group_project
.
path
)
end
end
context
'unauthenticated'
do
...
...
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