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
6becd151
Commit
6becd151
authored
Mar 11, 2021
by
Jose Vargas
Committed by
Douglas Barbosa Alexandre
Apr 19, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Readd missing data attribute, rework tests
parent
a3af6dbd
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
19 deletions
+15
-19
app/views/projects/pipelines/new.html.haml
app/views/projects/pipelines/new.html.haml
+0
-1
locale/gitlab.pot
locale/gitlab.pot
+0
-3
spec/features/projects/pipelines/pipelines_spec.rb
spec/features/projects/pipelines/pipelines_spec.rb
+15
-15
No files found.
app/views/projects/pipelines/new.html.haml
View file @
6becd151
-
breadcrumb_title
_
(
'Pipelines'
)
-
page_title
s_
(
'Pipeline|Run pipeline'
)
-
settings_link
=
link_to
_
(
'CI/CD settings'
),
project_settings_ci_cd_path
(
@project
)
%h3
.page-title
=
s_
(
'Pipeline|Run pipeline'
)
...
...
locale/gitlab.pot
View file @
6becd151
...
...
@@ -5562,9 +5562,6 @@ msgstr ""
msgid "CI/CD for external repo"
msgstr ""
msgid "CI/CD settings"
msgstr ""
msgid "CICDAnalytics|%{percent}%{percentSymbol}"
msgstr ""
...
...
spec/features/projects/pipelines/pipelines_spec.rb
View file @
6becd151
...
...
@@ -663,16 +663,20 @@ RSpec.describe 'Pipelines', :js do
context
'for valid commit'
,
:js
do
before
do
click_button
project
.
default_branch
wait_for_requests
find
(
'p'
,
text:
'master'
).
click
wait_for_requests
end
context
'with gitlab-ci.yml'
do
context
'with gitlab-ci.yml'
,
:js
do
before
do
stub_ci_pipeline_to_return_yaml_file
end
it
'creates a new pipeline'
do
expect
do
click_on
'Run
P
ipeline'
click_on
'Run
p
ipeline'
wait_for_requests
end
.
to
change
{
Ci
::
Pipeline
.
count
}.
by
(
1
)
...
...
@@ -684,19 +688,17 @@ RSpec.describe 'Pipelines', :js do
context
'when variables are specified'
do
it
'creates a new pipeline with variables'
do
page
.
within
(
all
(
"[data-testid='ci-variable-row']"
)[
0
]
)
do
page
.
within
(
find
(
"[data-testid='ci-variable-row']"
)
)
do
find
(
"[data-testid='pipeline-form-ci-variable-key']"
).
set
(
'key_name'
)
find
(
"[data-testid='pipeline-form-ci-variable-value']"
).
set
(
'value'
)
end
expect
do
click_on
'Run
P
ipeline'
click_on
'Run
p
ipeline'
wait_for_requests
end
.
to
change
{
Ci
::
Pipeline
.
count
}.
by
(
1
)
wait_for_requests
expect
(
Ci
::
Pipeline
.
last
.
variables
.
map
{
|
var
|
var
.
slice
(
:key
,
:secret_value
)
})
.
to
eq
[{
key:
"key_name"
,
secret_value:
"value"
}.
with_indifferent_access
]
end
...
...
@@ -705,18 +707,16 @@ RSpec.describe 'Pipelines', :js do
context
'without gitlab-ci.yml'
do
before
do
click_on
'Run
P
ipeline'
click_on
'Run
p
ipeline'
wait_for_requests
end
it
{
expect
(
page
).
to
have_content
(
'Missing CI config file'
)
}
it
'creates a pipeline after first request failed and a valid gitlab-ci.yml file is available when trying again'
do
click_button
project
.
default_branch
stub_ci_pipeline_to_return_yaml_file
expect
do
click_on
'Run
P
ipeline'
click_on
'Run
p
ipeline'
wait_for_requests
end
.
to
change
{
Ci
::
Pipeline
.
count
}.
by
(
1
)
...
...
@@ -787,8 +787,8 @@ RSpec.describe 'Pipelines', :js do
describe
'new pipeline page'
do
it
'has field to add a new pipeline'
do
expect
(
page
).
to
have_selector
(
'
.js-branch-select
'
)
expect
(
find
(
'
.js-branch-select
'
)).
to
have_content
project
.
default_branch
expect
(
page
).
to
have_selector
(
'
[data-testid="ref-select"]
'
)
expect
(
find
(
'
[data-testid="ref-select"]
'
)).
to
have_content
project
.
default_branch
expect
(
page
).
to
have_content
(
'Run for'
)
end
end
...
...
@@ -797,10 +797,10 @@ RSpec.describe 'Pipelines', :js do
it
'shows filtered pipelines'
,
:js
do
click_button
project
.
default_branch
page
.
within
'
.dropdown-menu
'
do
find
(
'
.dropdown-input-field
'
).
native
.
send_keys
(
'fix'
)
page
.
within
'
[data-testid="ref-select"]
'
do
find
(
'
[data-testid="search-refs"]
'
).
native
.
send_keys
(
'fix'
)
page
.
within
'.
dropdown-content
'
do
page
.
within
'.
gl-new-dropdown-contents
'
do
expect
(
page
).
to
have_content
(
'fix'
)
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