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
6ec7689c
Commit
6ec7689c
authored
Aug 02, 2021
by
Jose Vargas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Expose iid in the pipelines entity
Changelog: changed
parent
de0c2a54
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
1 deletion
+8
-1
app/serializers/ci/pipeline_entity.rb
app/serializers/ci/pipeline_entity.rb
+1
-0
doc/api/pipelines.md
doc/api/pipelines.md
+6
-0
spec/serializers/ci/pipeline_entity_spec.rb
spec/serializers/ci/pipeline_entity_spec.rb
+1
-1
No files found.
app/serializers/ci/pipeline_entity.rb
View file @
6ec7689c
...
...
@@ -7,6 +7,7 @@ class Ci::PipelineEntity < Grape::Entity
delegate
:name
,
:failure_reason
,
to: :presented_pipeline
expose
:id
expose
:iid
expose
:user
,
using:
UserEntity
expose
:active?
,
as: :active
...
...
doc/api/pipelines.md
View file @
6ec7689c
...
...
@@ -52,6 +52,7 @@ Example of response
[
{
"id"
:
47
,
"iid"
:
12
,
"project_id"
:
1
,
"status"
:
"pending"
,
"ref"
:
"new-pipeline"
,
...
...
@@ -62,6 +63,7 @@ Example of response
},
{
"id"
:
48
,
"iid"
:
13
,
"project_id"
:
1
,
"status"
:
"pending"
,
"ref"
:
"new-pipeline"
,
...
...
@@ -93,6 +95,7 @@ Example of response
```
json
{
"id"
:
46
,
"iid"
:
11
,
"project_id"
:
1
,
"status"
:
"success"
,
"ref"
:
"main"
,
...
...
@@ -281,6 +284,7 @@ Example of response
```
json
{
"id"
:
61
,
"iid"
:
21
,
"project_id"
:
1
,
"sha"
:
"384c444e840a515b23f21915ee5766b87068a70d"
,
"ref"
:
"main"
,
...
...
@@ -328,6 +332,7 @@ Response:
```
json
{
"id"
:
46
,
"iid"
:
11
,
"project_id"
:
1
,
"status"
:
"pending"
,
"ref"
:
"main"
,
...
...
@@ -375,6 +380,7 @@ Response:
```
json
{
"id"
:
46
,
"iid"
:
11
,
"project_id"
:
1
,
"status"
:
"canceled"
,
"ref"
:
"main"
,
...
...
spec/serializers/ci/pipeline_entity_spec.rb
View file @
6ec7689c
...
...
@@ -18,7 +18,7 @@ RSpec.describe Ci::PipelineEntity do
let
(
:pipeline
)
{
create
(
:ci_empty_pipeline
)
}
it
'contains required fields'
do
expect
(
subject
).
to
include
:id
,
:user
,
:path
,
:coverage
,
:source
expect
(
subject
).
to
include
:id
,
:
iid
,
:
user
,
:path
,
:coverage
,
:source
expect
(
subject
).
to
include
:ref
,
:commit
expect
(
subject
).
to
include
:updated_at
,
:created_at
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