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
27789634
Commit
27789634
authored
Jul 05, 2021
by
Ezekiel Kigbo
Committed by
Martin Wortschack
Jul 05, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Initialize VSA custom stages with a transition key
parent
bf1e288a
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
4 deletions
+18
-4
ee/app/assets/javascripts/analytics/cycle_analytics/components/value_stream_form.vue
...nalytics/cycle_analytics/components/value_stream_form.vue
+1
-1
ee/spec/features/groups/analytics/cycle_analytics/multiple_value_streams_spec.rb
.../analytics/cycle_analytics/multiple_value_streams_spec.rb
+10
-0
spec/support/helpers/cycle_analytics_helpers.rb
spec/support/helpers/cycle_analytics_helpers.rb
+7
-3
No files found.
ee/app/assets/javascripts/analytics/cycle_analytics/components/value_stream_form.vue
View file @
27789634
...
...
@@ -281,7 +281,7 @@ export default {
},
handleResetBlank
()
{
this
.
name
=
''
;
Vue
.
set
(
this
,
'
stages
'
,
[{
...
defaultCustomStageFields
}]
);
Vue
.
set
(
this
,
'
stages
'
,
initializeStages
(
this
.
defaultStageConfig
,
this
.
selectedPreset
)
);
},
onSelectPreset
()
{
if
(
this
.
selectedPreset
===
PRESET_OPTIONS_DEFAULT
)
{
...
...
ee/spec/features/groups/analytics/cycle_analytics/multiple_value_streams_spec.rb
View file @
27789634
...
...
@@ -15,6 +15,7 @@ RSpec.describe 'Multiple value streams', :js do
end
let
(
:extended_form_fields_selector
)
{
'[data-testid="extended-form-fields"]'
}
let
(
:preset_selector
)
{
'[data-testid="vsa-preset-selector"]'
}
let!
(
:default_value_stream
)
{
create
(
:cycle_analytics_group_value_stream
,
group:
group
,
name:
'default'
)
}
3
.
times
do
|
i
|
...
...
@@ -58,6 +59,15 @@ RSpec.describe 'Multiple value streams', :js do
expect
(
page
).
to
have_text
(
_
(
"'%{name}' Value Stream created"
)
%
{
name:
custom_value_stream_name
})
end
it
'can create a value stream with only custom stages'
do
page
.
find
(
preset_selector
).
choose
(
"Create from no template"
)
fill_in_custom_stage_fields
save_value_stream
(
custom_value_stream_name
)
expect
(
page
).
to
have_text
(
_
(
"'%{name}' Value Stream created"
)
%
{
name:
custom_value_stream_name
})
end
it
'can create a value stream with a custom stage and hidden defaults'
do
add_custom_stage_to_form
...
...
spec/support/helpers/cycle_analytics_helpers.rb
View file @
27789634
...
...
@@ -12,9 +12,7 @@ module CycleAnalyticsHelpers
page
.
all
(
'.gl-path-button'
).
collect
(
&
:text
).
map
{
|
name_with_median
|
name_with_median
.
split
(
"
\n
"
)[
0
]
}
end
def
add_custom_stage_to_form
page
.
find_button
(
s_
(
'CreateValueStreamForm|Add another stage'
)).
click
def
fill_in_custom_stage_fields
index
=
page
.
all
(
'[data-testid="value-stream-stage-fields"]'
).
length
last_stage
=
page
.
all
(
'[data-testid="value-stream-stage-fields"]'
).
last
...
...
@@ -25,6 +23,12 @@ module CycleAnalyticsHelpers
end
end
def
add_custom_stage_to_form
page
.
find_button
(
s_
(
'CreateValueStreamForm|Add another stage'
)).
click
fill_in_custom_stage_fields
end
def
save_value_stream
(
custom_value_stream_name
)
fill_in
'create-value-stream-name'
,
with:
custom_value_stream_name
...
...
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