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
466d3efd
Commit
466d3efd
authored
Mar 01, 2021
by
Sarah GP
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update specs for etag path
parent
93615feb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
app/assets/javascripts/pipelines/components/graph/graph_component.vue
...avascripts/pipelines/components/graph/graph_component.vue
+3
-1
spec/frontend/pipelines/graph/graph_component_wrapper_spec.js
.../frontend/pipelines/graph/graph_component_wrapper_spec.js
+9
-0
No files found.
app/assets/javascripts/pipelines/components/graph/graph_component.vue
View file @
466d3efd
...
@@ -19,7 +19,9 @@ export default {
...
@@ -19,7 +19,9 @@ export default {
type
:
Object
,
type
:
Object
,
required
:
true
,
required
:
true
,
validator
(
value
)
{
validator
(
value
)
{
return
Object
.
keys
(
value
).
includes
(
'
graphqlResourceEtag
'
);
return
(
Object
.
keys
(
value
).
includes
(
'
graphqlResourceEtag
'
)
&&
value
.
graphqlResourceEtag
.
length
>
0
);
},
},
},
},
pipeline
:
{
pipeline
:
{
...
...
spec/frontend/pipelines/graph/graph_component_wrapper_spec.js
View file @
466d3efd
...
@@ -9,6 +9,8 @@ import PipelineGraphWrapper from '~/pipelines/components/graph/graph_component_w
...
@@ -9,6 +9,8 @@ import PipelineGraphWrapper from '~/pipelines/components/graph/graph_component_w
import
{
mockPipelineResponse
}
from
'
./mock_data
'
;
import
{
mockPipelineResponse
}
from
'
./mock_data
'
;
const
defaultProvide
=
{
const
defaultProvide
=
{
graphqlResourceEtag
:
'
frog/amphibirama/etag/
'
,
metricsPath
:
''
,
pipelineProjectPath
:
'
frog/amphibirama
'
,
pipelineProjectPath
:
'
frog/amphibirama
'
,
pipelineIid
:
'
22
'
,
pipelineIid
:
'
22
'
,
};
};
...
@@ -87,6 +89,13 @@ describe('Pipeline graph wrapper', () => {
...
@@ -87,6 +89,13 @@ describe('Pipeline graph wrapper', () => {
it
(
'
displays the graph
'
,
()
=>
{
it
(
'
displays the graph
'
,
()
=>
{
expect
(
getGraph
().
exists
()).
toBe
(
true
);
expect
(
getGraph
().
exists
()).
toBe
(
true
);
});
});
it
(
'
passes the etag resource and metrics path to the graph
'
,
()
=>
{
expect
(
getGraph
().
props
(
'
configPaths
'
)).
toMatchObject
({
graphqlResourceEtag
:
defaultProvide
.
graphqlResourceEtag
,
metricsPath
:
defaultProvide
.
metricsPath
,
});
});
});
});
describe
(
'
when there is an error
'
,
()
=>
{
describe
(
'
when there is an error
'
,
()
=>
{
...
...
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